summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gnat.dg/specs/linker_section.ads
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/gnat.dg/specs/linker_section.ads')
-rw-r--r--gcc/testsuite/gnat.dg/specs/linker_section.ads13
1 files changed, 13 insertions, 0 deletions
diff --git a/gcc/testsuite/gnat.dg/specs/linker_section.ads b/gcc/testsuite/gnat.dg/specs/linker_section.ads
new file mode 100644
index 000000000..73e89aa48
--- /dev/null
+++ b/gcc/testsuite/gnat.dg/specs/linker_section.ads
@@ -0,0 +1,13 @@
+package Linker_Section is
+ Data1 : constant String := "12345678901234567";
+ pragma Linker_Section (Entity => Data1,
+ Section => ".eeprom");
+ type EEPROM_String is new String;
+ pragma Linker_Section (Entity => EEPROM_String, -- { dg-error "objects" }
+ Section => ".eeprom");
+ Data2 : constant EEPROM_String := "12345678901234567";
+ package Inner is end;
+ pragma Linker_Section (Entity => Inner, -- { dg-error "objects" }
+ Section => ".eeprom");
+end Linker_Section;
+