Default value of function parameter initialized by list initialization : <p>Could anyone help me with the following problem?</p>

<p>There is a simple code:</p>

<pre><code>#include &lt;vector&gt;

struct A {
    std::vector&lt;int&gt; vec;
};

void func (A &amp;&amp;a = {}) {}

int main()
{
    func();
    return 0;
}
</code></pre>

<p>When I try to compile it by gcc 5.4.0 I get the error:</p>

<pre><code>undefined reference to `std::vector&lt;int, std::allocator&lt;int&gt; &gt;::vector()'
</code></pre>

<p>Amazingly, but clang compiles it well.
Also if to modify the code a little bit it is compiled without any problems:</p>

<pre><code>#include &lt;vector&gt;

struct A {
    std::vector&lt;int&gt; vec;
};

void func (A &amp;&amp;a) {}

int main()
{
    func({});
    return 0;
}
</code></pre>

<p>I really cann't understand what's wrong with the first code.</p>
