From: Tom Tromey Date: Wed, 25 Jan 2023 16:26:53 +0000 (-0700) Subject: Use clean_restart in gdb.dlang X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=9b21b701bb5725071f5304d52a6aadad1f421e9e;p=binutils-gdb.git Use clean_restart in gdb.dlang Change gdb.dlang to use clean_restart more consistently. --- diff --git a/gdb/testsuite/gdb.dlang/demangle.exp b/gdb/testsuite/gdb.dlang/demangle.exp index 111042cbe78..c0ae92537e6 100644 --- a/gdb/testsuite/gdb.dlang/demangle.exp +++ b/gdb/testsuite/gdb.dlang/demangle.exp @@ -195,10 +195,7 @@ proc test_d_demangling {} { test_demangling "_D3std6socket23UnknownAddressReference6__ctorMFPS4core3sys5posix3sys6socket8sockaddrkZC3std6socket23UnknownAddressReference" "std.socket.UnknownAddressReference.this(core.sys.posix.sys.socket.sockaddr*, uint)" } -# Start with a fresh gdb. - -gdb_exit -gdb_start +clean_restart if [set_lang_d] { gdb_test_no_output "set width 0" diff --git a/gdb/testsuite/gdb.dlang/expression.exp b/gdb/testsuite/gdb.dlang/expression.exp index 2f80b3390a0..c7aeec52d25 100644 --- a/gdb/testsuite/gdb.dlang/expression.exp +++ b/gdb/testsuite/gdb.dlang/expression.exp @@ -127,10 +127,7 @@ proc test_d_expressions {} { gdb_test "print \[1, 2\] ~ \[2, 3\]" " = \\\{1, 2, 2, 3\\\}" } -# Start with a fresh gdb. - -gdb_exit -gdb_start +clean_restart if [set_lang_d] { test_d_integer_literals diff --git a/gdb/testsuite/gdb.dlang/primitive-types.exp b/gdb/testsuite/gdb.dlang/primitive-types.exp index 3fd6d2d6e41..7b284bad2f0 100644 --- a/gdb/testsuite/gdb.dlang/primitive-types.exp +++ b/gdb/testsuite/gdb.dlang/primitive-types.exp @@ -49,10 +49,7 @@ proc test_builtin_d_types_accepted {} { gdb_test "ptype dchar" "type = dchar" } -# Start with a fresh gdb. - -gdb_exit -gdb_start +clean_restart if [set_lang_d] { test_builtin_d_types_accepted diff --git a/gdb/testsuite/gdb.dlang/properties.exp b/gdb/testsuite/gdb.dlang/properties.exp index 474c18b3177..3b92a81e2ca 100644 --- a/gdb/testsuite/gdb.dlang/properties.exp +++ b/gdb/testsuite/gdb.dlang/properties.exp @@ -80,10 +80,7 @@ proc test_d_typeof {} { gdb_test "ptype typeof(7.0f ^^ 3)" "type = float" } -# Start with a fresh gdb. - -gdb_exit -gdb_start +clean_restart if [set_lang_d] { test_d_sizeof