This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Possible GCC C parser bug
- From: Toshi Morita <tm314159 at yahoo dot com>
- To: "gcc-bugs at gcc dot gnu dot org" <gcc-bugs at gcc dot gnu dot org>
- Date: Fri, 26 Aug 2016 20:43:54 +0000 (UTC)
- Subject: Possible GCC C parser bug
- Authentication-results: sourceware.org; auth=none
- References: <1542194575.395366.1472244234581.ref@mail.yahoo.com>
- Reply-to: Toshi Morita <tm314159 at yahoo dot com>
Tried to create an account on Bugzilla, won't let me create an account.
So posting directly to the bugs list.
cdecl says "const int const * pntr" is a syntax error.
GCC accepts the same construct without warning or error.
I suspect cdecl is correct.
user@hp-nx9420:~$ cdecl
Type `help' or `?' for help
cdecl> const int const * pntr
syntax error
cdecl> quit
user@hp-nx9420:~$ cat test.c
const int const * pntr;
user@hp-nx9420:~$ gcc -Wall -S test.c
user@hp-nx9420:~$
Toshi