diff options
author | jakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4> | 2008-09-26 05:09:29 +0000 |
---|---|---|
committer | jakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4> | 2008-09-26 05:09:29 +0000 |
commit | 64a7bd81fc18617c7bcd98b5eed6d842518533df (patch) | |
tree | b02577ee4e89f768c0114466de99d6a7f83a9969 /gcc/testsuite/gcc.dg/pr37645.c | |
parent | 36d2792f22664bab9d29254b8a5b55e14c3bdec4 (diff) | |
download | gcc-64a7bd81fc18617c7bcd98b5eed6d842518533df.tar.gz |
PR c/37645
* c-common.c (handle_weakref_attribute): Ignore the attribute unless
the decl is a VAR_DECL or FUNCTION_DECL.
* gcc.dg/pr37645.c: New test.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@140680 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/testsuite/gcc.dg/pr37645.c')
-rw-r--r-- | gcc/testsuite/gcc.dg/pr37645.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.dg/pr37645.c b/gcc/testsuite/gcc.dg/pr37645.c new file mode 100644 index 00000000000..ac1e5a9d1c8 --- /dev/null +++ b/gcc/testsuite/gcc.dg/pr37645.c @@ -0,0 +1,5 @@ +/* PR c/37645 */ +/* { dg-do compile } */ + +typedef int T __attribute__((__weakref__ ("U"))); /* { dg-warning "attribute ignored" } */ +void foo (int i __attribute__((__weakref__ ("j")))); /* { dg-warning "attribute ignored" } */ |