summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gnat.dg/sync1.adb
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/gnat.dg/sync1.adb')
-rw-r--r--gcc/testsuite/gnat.dg/sync1.adb15
1 files changed, 15 insertions, 0 deletions
diff --git a/gcc/testsuite/gnat.dg/sync1.adb b/gcc/testsuite/gnat.dg/sync1.adb
new file mode 100644
index 000000000..08be6395d
--- /dev/null
+++ b/gcc/testsuite/gnat.dg/sync1.adb
@@ -0,0 +1,15 @@
+-- { dg-do compile }
+package body sync1 is
+ protected body Chopstick is
+
+ entry Pick_Up when not Busy is
+ begin
+ Busy := True;
+ end Pick_Up;
+
+ procedure Put_Down is
+ begin
+ Busy := False;
+ end Put_Down;
+ end Chopstick;
+end sync1;