g++ cannot find the correct copy constructor when doing copy initialization
<p>With the following code:</p>

<pre><code>class B{};
class A{
public: 
    A(B&amp; b);
    A(const A&amp; a);  
};
A::A(B&amp; b){
}
A::A(A&amp; a){
}
int main(){
    B b;
    A a = b;
}
</code></pre>

<p>no matching function call to 'A::A(A)'</p>

<p>I looked up some references, and thought it might caused by the Return Value Optimization (RVO), so I tried to disable the optimization by the -fno-elide-constructor option. Problem still remains. </p>
