c-tree.h (enum c_storage_class): New.
authorJoseph Myers <jsm@polyomino.org.uk>
Sat, 11 Sep 2004 21:29:42 +0000 (22:29 +0100)
committerJoseph Myers <jsm28@gcc.gnu.org>
Sat, 11 Sep 2004 21:29:42 +0000 (22:29 +0100)
commit9a26d6ee086c424a32fefd09f55ff314afc2a051
tree2e7db2782d1466e19e91914d252ee32d24f2052e
parente6858057449b72a53389616073b72b3778c2cf63
c-tree.h (enum c_storage_class): New.

* c-tree.h (enum c_storage_class): New.
(struct c_declspecs): Add storage_class, inline_p and thread_p.
* c-decl.c (shadow_tag_warned): Give errors for "inline" in empty
declarations and "auto" or "register" in file scope empty
declarations.  Give more specific warnings for other cases of
storage class specifiers in empty declarations.
(grokdeclarator): Update for new structures.  Don't check for
multiple storage classes.  Diagnose file-scope "register" if
pedantic.
(build_null_declspecs): Update.
(declspecs_add_scspec): Update.  Diagnose multiple storage class
specifiers and invalid uses of "__thread".

testsuite:
* gcc.dg/declspec-4.c, gcc.dg/declspec-5.c, gcc.dg/declspec-6.c,
gcc.dg/tls/diag-2.c: Update expected messages.
* gcc.dg/991209-1.c: Specify compilation options.  Update expected
messages.
* gcc.dg/pr14289-2.c, gcc.dg/pr14289-3.c: Remove.
* gcc.dg/declspec-7.c, gcc.dg/declspec-8.c, gcc.dg/declspec-9.c,
gcc.dg/declspec-10.c, gcc.dg/declspec-11.c, gcc.dg/tls/diag-4.c,
gcc.dg/tls/diag-5.c: New tests.

From-SVN: r87374
17 files changed:
gcc/ChangeLog
gcc/c-decl.c
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/991209-1.c
gcc/testsuite/gcc.dg/declspec-10.c [new file with mode: 0644]
gcc/testsuite/gcc.dg/declspec-11.c [new file with mode: 0644]
gcc/testsuite/gcc.dg/declspec-4.c
gcc/testsuite/gcc.dg/declspec-5.c
gcc/testsuite/gcc.dg/declspec-6.c
gcc/testsuite/gcc.dg/declspec-7.c [new file with mode: 0644]
gcc/testsuite/gcc.dg/declspec-8.c [new file with mode: 0644]
gcc/testsuite/gcc.dg/declspec-9.c [new file with mode: 0644]
gcc/testsuite/gcc.dg/pr14289-2.c [deleted file]
gcc/testsuite/gcc.dg/pr14289-3.c [deleted file]
gcc/testsuite/gcc.dg/tls/diag-2.c
gcc/testsuite/gcc.dg/tls/diag-4.c [new file with mode: 0644]
gcc/testsuite/gcc.dg/tls/diag-5.c [new file with mode: 0644]