]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
Minor test fix for gnat-llvm
authorTom Tromey <tromey@adacore.com>
Tue, 16 Dec 2025 21:34:30 +0000 (14:34 -0700)
committerTom Tromey <tromey@adacore.com>
Wed, 17 Dec 2025 14:14:46 +0000 (07:14 -0700)
This patch fixes a spot in the gdb test suite where gnat-llvm seems to
emit slightly better DWARF than GNAT.

gdb/testsuite/gdb.ada/packed_record_2.exp

index af2509b73b8a34b27625d3f3b1a4305d66ffd849..14e03c1e63b6b46bb350d4062cdba91b852b9a32 100644 (file)
@@ -41,13 +41,14 @@ gdb_test "print spr.discr" " = 3"
 
 # See PR ada/32880 -- gdb should probably print array (1 .. 3) here,
 # but instead shows array (<>).  However as this isn't totally
-# relevant to this test, we just accept it.
+# relevant to this test, we just accept it.  Also, while gnat-llvm
+# successfully uses the type names, GNAT just emits the ranges here.
 gdb_test "ptype spr" \
     [multi_line \
         "type = tagged record" \
-        "    discr: range 1 .. 8;" \
-        "    field: range -7 .. -4;" \
-        "    array_field: array \\(<>\\) of exam.small <packed: 2-bit elements>;" \
+        "    discr: (range 1 .. 8|range_int);" \
+        "    field: (range -7 .. -4|small);" \
+        "    array_field: array \\(<>\\) of (exam.)?small <packed: 2-bit elements>;" \
         "end record"]
 
 gdb_test_multiple "print sc" "" {