https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117866
Sam James <sjames at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|Confusing 'expected ... but |[15 regression] Confusing |argument is of type ...' |'expected ... but argument |(same type repeated) |is of type ...' (same type | |repeated) --- Comment #1 from Sam James <sjames at gcc dot gnu.org> --- With -std=gnu17, we do this right. # gcc paths.i -fmax-errors=1 -Wall -Wextra -std=gnu17 In file included from paths.c:47: spaces.h:63:31: warning: ‘struct fractpoint’ declared inside parameter list will not be visible outside of this definition or declaration 63 | void (*convert)(struct fractpoint *pt, struct XYspace *S, float X, float Y); /* calculate "fractpoint" X,Y from float X,Y */ | ^~~~~~~~~~ spaces.h:64:32: warning: ‘struct fractpoint’ declared inside parameter list will not be visible outside of this definition or declaration 64 | void (*iconvert)(struct fractpoint *pt, struct XYspace *S, int X, int Y); /* calculate "fractpoint" X,Y from int X,Y */ | ^~~~~~~~~~ paths.c: In function ‘t1_Loc’: paths.c:219:22: error: passing argument 1 of ‘S->convert’ from incompatible pointer type [-Wincompatible-pointer-types] 219 | r->context = S->context; | ^~~~~~~~ | | | struct fractpoint * paths.c:219:22: note: expected ‘struct fractpoint *’ but argument is of type ‘struct fractpoint *’ Hence a regression in the default mode.