title: why isnt temprorary ojbect constructor called?
body: <p>please check out the code below :</p>
  <pre><code>#include &lt;iostream&gt;
  using namespace std;
  struct A{
      A(char* str) { cout &lt;&lt; &quot;default called&quot; &lt;&lt; endl; }
      A(const A &amp;a) { cout &lt;&lt; &quot;copy called&quot; &lt;&lt; endl; }
  };
  int main() {
      A obj  = &quot;str&quot;;
  }
  </code></pre>
  <p>the Output is :</p>
  <pre><code>default called
  </code></pre>
  <p>why when i initialize object ,the consturctor of temprorary object isnt called ??
  doesnt</p>
  <pre><code>A obj  = &quot;str&quot;;
  </code></pre>
  <p>turn into</p>
  <pre><code>A obj = A(&quot;str&quot;) // so why consturctor of temprorary object isnt called ?? 
  </code></pre>
  <p>???</p>
  <p>i know about Copy elision little bit that why copy constructor of <code>obj</code> isnt called
  but why cosntructor of temprorary ojbect isnt called ??</p>
  <p>Thanks!</p>