summaryrefslogtreecommitdiffstats
path: root/test/Sema/attr-section.c
diff options
context:
space:
mode:
Diffstat (limited to 'test/Sema/attr-section.c')
-rw-r--r--test/Sema/attr-section.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/test/Sema/attr-section.c b/test/Sema/attr-section.c
index 20ae2e3..614f294 100644
--- a/test/Sema/attr-section.c
+++ b/test/Sema/attr-section.c
@@ -8,3 +8,8 @@ int x __attribute__((section(
int y __attribute__((section(
"sadf"))); // expected-error {{mach-o section specifier requires a segment and section separated by a comma}}
+// PR6007
+void test() {
+ __attribute__((section("NEAR,x"))) int n1; // expected-error {{'section' attribute is not valid on local variables}}
+ __attribute__((section("NEAR,x"))) static int n2; // ok.
+} \ No newline at end of file
OpenPOWER on IntegriCloud