https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101106
Bug ID: 101106
Summary: [11 regression] =delete on second declaration of the
same function produces a note with no error
Product: gcc
Version: 11.1.1
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: jlegg at feralinteractive dot com
Target Milestone: ---
GCC 10.3 correctly ([dcl.fct.def.delete] paragraph 4) diagnosed a "deleted
definition of 'int f()'" error for:
int f();
int f() = delete;
However, GCC 11.1 doesn't emit the error part of the diagnostic, which pointed
at the location of the deleted definition. It still emits a note pointing at
the previous declaration, with no associated error or warning.
This is possibly related to bug 90703. Unlike the example in that bug, this
previously was correctly rejected however.