diff options
author | Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org> | 2015-06-03 15:10:44 +0000 |
---|---|---|
committer | Prathamesh Kulkarni <prathamesh3492@gcc.gnu.org> | 2015-06-03 15:10:44 +0000 |
commit | bc51ace3600b5c9b5dcad09f16858e5727866e27 (patch) | |
tree | 3096135066177486fe57c67c799c10f0bcb121e2 /gcc/testsuite/c-c++-common/pr58346-1.c | |
parent | 80a4fe78bf071c07a71f640bd861193b85c27138 (diff) | |
download | gcc-bc51ace3600b5c9b5dcad09f16858e5727866e27.zip gcc-bc51ace3600b5c9b5dcad09f16858e5727866e27.tar.gz gcc-bc51ace3600b5c9b5dcad09f16858e5727866e27.tar.bz2 |
c-decl.c (warn_cxx_compat_finish_struct): New parameters code, record_loc.
2015-06-03 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
c/
* c-decl.c (warn_cxx_compat_finish_struct): New parameters code, record_loc.
Warn for empty struct.
(finish_struct): Pass TREE_CODE(t) and loc to warn_cxx_compat_finish_struct.
testsuite/
* gcc.dg/Wcxx-compat-22.c: New testcase.
* c-c++-common/Wsizeof-pointer-memaccess1.c: Pass -Wno-c++-compat.
* c-c++-common/Wsizeof-pointer-memaccess2.c: Likewise.
* c-c++-common/pr58346-1.c: Likewise.
* c-c++-common/transparent-union-1.c: Likewise.
From-SVN: r224083
Diffstat (limited to 'gcc/testsuite/c-c++-common/pr58346-1.c')
-rw-r--r-- | gcc/testsuite/c-c++-common/pr58346-1.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/gcc/testsuite/c-c++-common/pr58346-1.c b/gcc/testsuite/c-c++-common/pr58346-1.c index 371fcf4..70a16d1 100644 --- a/gcc/testsuite/c-c++-common/pr58346-1.c +++ b/gcc/testsuite/c-c++-common/pr58346-1.c @@ -1,5 +1,6 @@ /* PR c/58346 */ /* { dg-do compile } */ +/* { dg-options "-Wno-c++-compat" { target c } } */ struct U { #ifdef __cplusplus |