[gdb/testsuite] Improve untested message in gdb.ada/finish-var-size.exp
authorTom de Vries <tdevries@suse.de>
Tue, 7 Feb 2023 10:41:44 +0000 (11:41 +0100)
committerTom de Vries <tdevries@suse.de>
Tue, 7 Feb 2023 10:41:44 +0000 (11:41 +0100)
I came across:
...
UNTESTED: gdb.ada/finish-var-size.exp: GCC too told for this test
...
The message only tells us that the compiler version too old, not what compiler
version is required.

Fix this by rewriting using required:
...
UNSUPPORTED: gdb.ada/finish-var-size.exp: require failed: \
  expr [gcc_major_version] >= 12
...

Tested on x86_64-linux.

gdb/testsuite/gdb.ada/finish-var-size.exp

index c1cf6406433f9ed3951a181ca22b44e007171ef6..5865be249a05e31fb8ef8be547e86a885671036f 100644 (file)
@@ -18,10 +18,7 @@ load_lib "ada.exp"
 require allow_ada_tests
 
 # GCC 12 has the needed fix.
-if {![test_compiler_info {gcc-1[2-9]-*}]} {
-    untested "GCC too told for this test"
-    return -1
-}
+require {expr [gcc_major_version] >= 12}
 
 standard_ada_testfile p