aboutsummaryrefslogtreecommitdiff
path: root/ld/testsuite
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2020-01-27 10:51:52 +1030
committerAlan Modra <amodra@gmail.com>2020-01-27 22:52:15 +1030
commite3696f67abfc46dcac6c9bbe47f8e25e34b17be5 (patch)
treee241615305663b2d2fee857efefb7001014b78b1 /ld/testsuite
parent7568c93bf95a518797dfb2987b04911164c14a36 (diff)
downloadbinutils-e3696f67abfc46dcac6c9bbe47f8e25e34b17be5.zip
binutils-e3696f67abfc46dcac6c9bbe47f8e25e34b17be5.tar.gz
binutils-e3696f67abfc46dcac6c9bbe47f8e25e34b17be5.tar.bz2
Replace deprecated tcl case statements with switch statements
binutils/ * testsuite/lib/binutils-common.exp (big_or_little_endian): Replace case statement with switch statement. gas/ * testsuite/gas/all/gas.exp: Replace case statements with switch statements. * testsuite/gas/elf/elf.exp: Likewise. * testsuite/gas/macros/macros.exp: Likewise. * testsuite/lib/gas-defs.exp: Likewise. ld/ * testsuite/ld-elfvers/vers.exp: Replace case statements with switch statements. * testsuite/ld-ifunc/ifunc.exp: Likewise. * testsuite/ld-unique/unique.exp: Likewise.
Diffstat (limited to 'ld/testsuite')
-rw-r--r--ld/testsuite/ld-elfvers/vers.exp6
-rw-r--r--ld/testsuite/ld-ifunc/ifunc.exp4
-rw-r--r--ld/testsuite/ld-unique/unique.exp4
3 files changed, 7 insertions, 7 deletions
diff --git a/ld/testsuite/ld-elfvers/vers.exp b/ld/testsuite/ld-elfvers/vers.exp
index e0ece08..6ab1e75 100644
--- a/ld/testsuite/ld-elfvers/vers.exp
+++ b/ld/testsuite/ld-elfvers/vers.exp
@@ -92,9 +92,9 @@ if { [istarget mips*-*-*] && ! [at_least_gcc_version 4 3] } then {
}
}
-case $target_triplet in {
- { ia64-*-* } { set as_options "-x" }
- { sparc-*-* } { set as_options "-Av9a" }
+switch -glob $target_triplet {
+ ia64-*-* { set as_options "-x" }
+ sparc-*-* { set as_options "-Av9a" }
default { set as_options "" }
}
diff --git a/ld/testsuite/ld-ifunc/ifunc.exp b/ld/testsuite/ld-ifunc/ifunc.exp
index 3ef3224..4e9e83b 100644
--- a/ld/testsuite/ld-ifunc/ifunc.exp
+++ b/ld/testsuite/ld-ifunc/ifunc.exp
@@ -268,8 +268,8 @@ if { $fails == 0 } {
# ifunc should have an OSABI field of GNU. The linked non-ifunc using
# executable should have an OSABI field of NONE (aka System V).
-case $target_triplet in {
- { hppa*-*-linux* } { set expected_none {UNIX - GNU} }
+switch -glob $target_triplet {
+ hppa*-*-linux* { set expected_none {UNIX - GNU} }
default { set expected_none {UNIX - System V} }
}
diff --git a/ld/testsuite/ld-unique/unique.exp b/ld/testsuite/ld-unique/unique.exp
index f9dd870..5457deb 100644
--- a/ld/testsuite/ld-unique/unique.exp
+++ b/ld/testsuite/ld-unique/unique.exp
@@ -163,8 +163,8 @@ if { $fails == 0 } {
}
# Check the empty object file.
-case $target_triplet in {
- { hppa*-*-linux* } { set expected_none {UNIX - GNU} }
+switch -glob $target_triplet {
+ hppa*-*-linux* { set expected_none {UNIX - GNU} }
default { set expected_none {UNIX - System V} }
}
if {! [check_osabi tmpdir/unique_empty.o $expected_none]} {