aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gdb/testsuite/ChangeLog7
-rw-r--r--gdb/testsuite/gdb.ada/vla.exp8
-rw-r--r--gdb/testsuite/gdb.ada/vla/vla.adb5
3 files changed, 16 insertions, 4 deletions
diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog
index 37e327d..bd48c92 100644
--- a/gdb/testsuite/ChangeLog
+++ b/gdb/testsuite/ChangeLog
@@ -1,3 +1,10 @@
+2019-06-14 Tom Tromey <tromey@adacore.com>
+
+ PR ada/24539:
+ * gdb.ada/vla.exp: Update tests.
+ * gdb.ada/vla/vla.adb (Record_Type): Use No_Component_Reordering
+ pragma.
+
2019-06-13 Pedro Alves <palves@redhat.com>
* gdb.base/settings.exp (test-integer): Test junk after
diff --git a/gdb/testsuite/gdb.ada/vla.exp b/gdb/testsuite/gdb.ada/vla.exp
index 7e10e9b..c03d1cc 100644
--- a/gdb/testsuite/gdb.ada/vla.exp
+++ b/gdb/testsuite/gdb.ada/vla.exp
@@ -29,10 +29,10 @@ set bp_location [gdb_get_line_number "Set breakpoint here" ${testdir}/vla.adb]
runto "vla.adb:$bp_location"
gdb_test "print r00" \
- "= \\(l1 => 0, l2 => 0, i1 => 1, i2 => 2, i3 => 3, a1 => \\(\\), a2 => \\(\\)\\)"
+ "= \\(l1 => 0, l2 => 0, i1 => 1, a1 => \\(\\), i2 => 2, a2 => \\(\\), i3 => 3\\)"
gdb_test "print r01" \
- "= \\(l1 => 0, l2 => 1, i1 => 1, i2 => 2, i3 => 3, a1 => \\(\\), a2 => \\(20\\)\\)"
+ "= \\(l1 => 0, l2 => 1, i1 => 1, a1 => \\(\\), i2 => 2, a2 => \\(20\\), i3 => 3\\)"
gdb_test "print r10" \
- "= \\(l1 => 1, l2 => 0, i1 => 1, i2 => 2, i3 => 3, a1 => \\(10\\), a2 => \\(\\)\\)"
+ "= \\(l1 => 1, l2 => 0, i1 => 1, a1 => \\(10\\), i2 => 2, a2 => \\(\\), i3 => 3\\)"
gdb_test "print r22" \
- "= \\(l1 => 2, l2 => 2, i1 => 1, i2 => 2, i3 => 3, a1 => \\(10, 10\\), a2 => \\(20, 20\\)\\)"
+ "= \\(l1 => 2, l2 => 2, i1 => 1, a1 => \\(10, 10\\), i2 => 2, a2 => \\(20, 20\\), i3 => 3\\)"
diff --git a/gdb/testsuite/gdb.ada/vla/vla.adb b/gdb/testsuite/gdb.ada/vla/vla.adb
index 2b6cc8a..1986fb1 100644
--- a/gdb/testsuite/gdb.ada/vla/vla.adb
+++ b/gdb/testsuite/gdb.ada/vla/vla.adb
@@ -23,6 +23,11 @@ procedure Vla is
I3 : Integer;
end record;
+ -- Some versions of GCC emit the members in the incorrect order.
+ -- Since this isn't relevant to the bug at hand, disable
+ -- reordering to get consistent results.
+ pragma No_Component_Reordering (Record_Type);
+
procedure Process (R : Record_Type) is
begin
null;