https://gcc.gnu.org/bugzilla/show_bug.cgi?id=20385

Eric Gallager <egallager at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED

--- Comment #12 from Eric Gallager <egallager at gcc dot gnu.org> ---
(In reply to Eric Gallager from comment #11)
> 
> So can this be closed as FIXED now then?

I combined all the examples from this PR into a single testcase and can confirm
that gcc now prints decent errors for all of them:

$ cat 20385.c
unknowntype f() { return 0; }
unknowntype *fp() { return 0; }
int ff(unknowntype a) { return 0; }
int gg(unknowntype *a) { return 0; }

typedef uintt16_t pid_t;
extern uintt16_t x;
foo_t *P = 0;
$ /usr/local/bin/gcc -c 20385.c
20385.c:1:1: error: unknown type name ‘unknowntype’
 unknowntype f() { return 0; }
 ^~~~~~~~~~~
20385.c:2:1: error: unknown type name ‘unknowntype’
 unknowntype *fp() { return 0; }
 ^~~~~~~~~~~
20385.c:3:8: error: unknown type name ‘unknowntype’
 int ff(unknowntype a) { return 0; }
        ^~~~~~~~~~~
20385.c:4:8: error: unknown type name ‘unknowntype’
 int gg(unknowntype *a) { return 0; }
        ^~~~~~~~~~~
20385.c:6:9: error: unknown type name ‘uintt16_t’
 typedef uintt16_t pid_t;
         ^~~~~~~~~
20385.c:7:8: error: unknown type name ‘uintt16_t’
 extern uintt16_t x;
        ^~~~~~~~~
20385.c:8:1: error: unknown type name ‘foo_t’; did you mean ‘float’?
 foo_t *P = 0;
 ^~~~~
 float

So I'm going to close this as FIXED.

Reply via email to