title: Qt Creator: different behavior of class template in Debug and Release modes
body: <p>I'm trying to specialize template member function. The problem is that in Debug mode calls specialization of method, but in Release calls non-specialized function.</p>
  
  <p>For example, I have class template and specialized method</p>
  
  <pre><code>template &lt;typename T&gt;
  class SimpleClass
  {
  public:
      void doSomething(const T&amp; arg)
      {
          std::cout &lt;&lt; "doSomething(const T&amp; arg)" &lt;&lt; std::endl;
      }
  };
  template &lt;&gt;
  void SimpleClass&lt;double&gt;::doSomething(const double&amp; arg)
  {
      std::cout &lt;&lt; "doSomething(const double&amp; arg)" &lt;&lt; std::endl;
  }
  
  int main(int argc, char **argv)
  {
      SimpleClass&lt;double&gt; obj;
      obj.doSomething(1);
      return 0;
  }
  </code></pre>
  
  <p>I'm expecting, that output will <code>"doSomething(const double&amp; arg)"</code>. </p>
  
  <p>So in Debug mode I got it, but in Release I got this: <code>"doSomething(const T&amp; arg)"</code></p>
  
  <p>My question is why that code behave this way and how can I fix it?
  Just in case, my .pro file</p>
  
  <pre><code>TEMPLATE = app
  CONFIG += console c++11
  CONFIG -= app_bundle
  SOURCES += main.cpp \
      mathop.cpp
  HEADERS += \
      mathop.h
  </code></pre>
  
  <p>edit: I'm using Qt 5.9.1</p>
  
  <p>edit: forgot <code>#include &lt;iostream&gt;</code> before using <code>cout</code></p>