summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gnat.dg/pack2.adb
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/gnat.dg/pack2.adb')
-rw-r--r--gcc/testsuite/gnat.dg/pack2.adb22
1 files changed, 22 insertions, 0 deletions
diff --git a/gcc/testsuite/gnat.dg/pack2.adb b/gcc/testsuite/gnat.dg/pack2.adb
new file mode 100644
index 000000000..7837c8ad8
--- /dev/null
+++ b/gcc/testsuite/gnat.dg/pack2.adb
@@ -0,0 +1,22 @@
+-- { dg-do compile }
+-- { dg-options "-gnatws" }
+
+procedure Pack2 is
+
+ type Bits_T is record
+ B0, B1, B2: Boolean;
+ end record;
+
+ type State_T is record
+ Valid : Boolean;
+ Value : Bits_T;
+ end record;
+ pragma Pack (State_T);
+
+ procedure Process (Bits : Bits_T) is begin null; end;
+
+ State : State_T;
+
+begin
+ Process (State.Value);
+end;