blob: 90d77dbd708603548db6e8e45d2f055735019859 [file] [log] [blame]
// PR c++/58714
// { dg-do run }
struct X {
X& operator=(const X&);
X& operator=(X&){__builtin_abort();}
};
X g;
X& X::operator=(const X&)
{
return g;
}
int main(int argv,char**) {
X a, b;
((argv > 2) ? a : b) = X();
}