https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99304
Bug ID: 99304 Summary: typo in diagnostic: refernced Product: gcc Version: 11.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c Assignee: unassigned at gcc dot gnu.org Reporter: roland.illig at gmx dot de Target Milestone: --- gcc/c-family/c-attribs.c says: > "refernced symbol declared here" That should be "referenced" instead. A test to trigger this diagnostic is: ~~~c /* { dg-do compile } */ /* { dg-options "-O2 -Wall" } */ void invalid_free(/* no prototype */); /* { dg-message "referenced" } */ void *invalid_malloc(void) __attribute__(( malloc(invalid_free) /* { dg-warning "must take a pointer" } */ )); ~~~ A test to trigger the closely related diagnostic is: ~~~c /* { dg-do compile } */ /* { dg-options "-O2 -Wall" } */ void invalid_free(int); /* { dg-message "referenced" } */ void *invalid_malloc(void) __attribute__(( malloc(invalid_free) /* { dg-warning "must take a pointer" } */ )); ~~~