From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 1726) id 645673858406; Mon, 10 Oct 2022 09:29:07 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 645673858406 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1665394147; bh=/OoiOxKw8hJH2tJM/nYCZCumTZNtp2E8BQSr7LAeF6I=; h=From:To:Subject:Date:From; b=ObJgrJRmjvIa+jJUuUxe7QmHiYx0cGcdGou82YPGaed9fg3X2OeZVGvwGQaaEKftu hokx/TKD3EDdq/PvAdzLcdCa4G1m69rL43X/qYvrn2VwI/hSafe+TYBZ0lQ8WR1tjH aYiT60fXJHMpmkYm/Z7Pc9Z0RRauHFsR9PtRIYHk= Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable From: Andrew Burgess To: gdb-cvs@sourceware.org Subject: [binutils-gdb] gdb/testsuite: use 'end' at the end of python blocks X-Act-Checkin: binutils-gdb X-Git-Author: Andrew Burgess X-Git-Refname: refs/heads/master X-Git-Oldrev: d549d8d23db0c12986d98bcb8e393939409237b5 X-Git-Newrev: f91822c2b9f9fed0c2717b17f380e5216502ea32 Message-Id: <20221010092907.645673858406@sourceware.org> Date: Mon, 10 Oct 2022 09:29:07 +0000 (GMT) List-Id: https://sourceware.org/git/gitweb.cgi?p=3Dbinutils-gdb.git;h=3Df91822c2b9f9= fed0c2717b17f380e5216502ea32 commit f91822c2b9f9fed0c2717b17f380e5216502ea32 Author: Andrew Burgess Date: Sat Oct 8 16:58:00 2022 +0100 gdb/testsuite: use 'end' at the end of python blocks =20 Within the testsuite, use the keyword 'end' to terminate blocks of Python code being sent to GDB, rather than sending \004. I could only find three instances of this, all in tests that I originally wrote. I have no memory of there being any special reason why I used \004 instead of 'end' - I assume I copied this from somewhere else that has since changed. =20 Non of the tests being changed here are specifically about whether \004 can be used to terminate a Python block, so I think switching to the more standard 'end' keyword is the right choice. Diff: --- gdb/testsuite/gdb.base/style.exp | 2 +- gdb/testsuite/gdb.python/py-arch-reg-groups.exp | 2 +- gdb/testsuite/gdb.python/py-arch-reg-names.exp | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/gdb/testsuite/gdb.base/style.exp b/gdb/testsuite/gdb.base/styl= e.exp index c6ed996c280..146e2b6d757 100644 --- a/gdb/testsuite/gdb.base/style.exp +++ b/gdb/testsuite/gdb.base/style.exp @@ -444,7 +444,7 @@ proc test_disassembler_error_handling { } { "def replacement_colorize_disasm(content,gdbarch):" \ " return None" \ "gdb.styling.colorize_disasm =3D replacement_colorize_disasm" \ - "\004"] \ + "end"] \ "setup replacement colorize_disasm function" \ true =20 diff --git a/gdb/testsuite/gdb.python/py-arch-reg-groups.exp b/gdb/testsuit= e/gdb.python/py-arch-reg-groups.exp index 9503e6c10f5..f2cf8b0e6ec 100644 --- a/gdb/testsuite/gdb.python/py-arch-reg-groups.exp +++ b/gdb/testsuite/gdb.python/py-arch-reg-groups.exp @@ -102,5 +102,5 @@ gdb_py_test_silent_cmd \ " raise gdb.GdbError (\"miss-matched names\")" \ " if (r1 !=3D r2):" \ " raise gdb.GdbError (\"miss-matched objects\")" \ - "\004" ] \ + "end" ] \ "check names and objects match" 1 diff --git a/gdb/testsuite/gdb.python/py-arch-reg-names.exp b/gdb/testsuite= /gdb.python/py-arch-reg-names.exp index d3c600ffc0f..62c47e8200e 100644 --- a/gdb/testsuite/gdb.python/py-arch-reg-names.exp +++ b/gdb/testsuite/gdb.python/py-arch-reg-names.exp @@ -102,7 +102,7 @@ gdb_py_test_silent_cmd \ " raise gdb.GdbError (\"miss-matched names\")" \ " if (r1 !=3D r2):" \ " raise gdb.GdbError (\"miss-matched objects\")" \ - "\004" ] \ + "end" ] \ "check names and objects match" 1 =20 # Ensure that the '.find' method on the iterator returns the same