[Bug c++/80858] When trying to copy std::unordered_map illegally, error message doesn't tell what's wrong
sgunderson at bigfoot dot com
gcc-bugzilla@gcc.gnu.org
Tue May 23 01:47:00 GMT 2017
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80858
--- Comment #4 from sgunderson at bigfoot dot com ---
I think this should work as reduction:
struct Empty {
};
template<class T>
struct A
{
A &operator=(const A&)
{
T t(3);
return *this;
}
};
class B
{
A<Empty> a;
};
int main(void)
{
B b1, b2;
b1 = b2;
}
The error is attributed to the line with “class B”, without ever mentioning the
“b1 = b2;” line.
More information about the Gcc-bugs
mailing list