https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68668
--- Comment #3 from Marek Polacek <mpolacek at gcc dot gnu.org> ---
I'm using slightly adjusted testcase:
typedef const int T[];
int
fn1 (T p)
{
return p[0];
}
It looks like grokdeclarator creates a wrong type for PARM_DECL "p". It says
its type is "const int[<unknown>] *", but that doesn't seem to be correct, it
should be "const int *". That also the reason why we generate this bogus
warning:
m.c:5:10: warning: return makes integer from pointer without a cast
[-Wint-conversion]
return p[0];
^