https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80858
--- Comment #9 from Jonathan Wakely ---
The problem isn't limited to implicitly-declared special members. If we adjust
comment 4 so that B::operator=(const B&) is user-declared but defined as
defaulted:
struct Empty {
};
template
struct A
{
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80858
--- Comment #8 from Jonathan Wakely ---
(In reply to Jonathan Wakely from comment #7)
> :5:8: required from here
> /opt/compiler-explorer/gcc-13.2.0/include/c++/13.2.0/bits/unique_ptr.h:97:23:
> error: invalid application of 'sizeof' to incompl
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80858
Jonathan Wakely changed:
What|Removed |Added
See Also||https://gcc.gnu.org/bugzill
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80858
Jonathan Wakely changed:
What|Removed |Added
CC||accelerator0099 at gmail dot
com
---
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80858
--- Comment #5 from Jonathan Wakely ---
Yes, that's great, thanks.
As you observed, Clang doesn't indicate the location that triggers the invalid
instantiation, but EDG does, correctly pointing to line 22:
"um2.cc", line 9: error: no suitable c
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
struct A
{
A &operator=(const A&)
{
T t(3);
return *this;
}
}
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80858
Jonathan Wakely changed:
What|Removed |Added
Keywords||diagnostic
Status|UNCONFIR
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80858
--- Comment #2 from sgunderson at bigfoot dot com ---
Yes, I mean that the error message isn't clear (and it's basically the same
error message in 4.8, so no regression).
I don't think I understand the difficulties involved. Doesn't the error com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80858
--- Comment #1 from Jonathan Wakely ---
(In reply to sgunderson from comment #0)
> Using gcc version 7.1.0 (Debian 7.1.0-5) (but the error goes back to at
> least 4.8, and amazingly, also in Clang), on this piece of code, simplified
> from a much