summaryrefslogtreecommitdiff
path: root/test/SemaCXX/attr-weakref.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'test/SemaCXX/attr-weakref.cpp')
-rw-r--r--test/SemaCXX/attr-weakref.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/test/SemaCXX/attr-weakref.cpp b/test/SemaCXX/attr-weakref.cpp
index a34579198fef..f3d7a6241c91 100644
--- a/test/SemaCXX/attr-weakref.cpp
+++ b/test/SemaCXX/attr-weakref.cpp
@@ -28,4 +28,7 @@ int a7() __attribute__((weakref ("f1"))); // expected-error {{weakref declaratio
int a8 __attribute__((weakref ("v1"))); // expected-error {{weakref declaration must have internal linkage}}
// gcc accepts this
-int a9 __attribute__((weakref)); // expected-error {{weakref declaration must have internal linkage}}
+int a9 __attribute__((weakref)); // expected-error {{weakref declaration of 'a9' must also have an alias attribute}}
+
+static int a10();
+int a10() __attribute__((weakref ("foo")));