public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
From: Martin Galvan <martin.galvan@tallertechnologies.com>
To: gdb-patches@sourceware.org,	qiyaoltc@gmail.com,	dje@google.com
Subject: [PATCH] testsuite: Remove the unneeded escaping of '[' and ']' characters in test_class_help
Date: Sun, 28 Jun 2015 04:01:00 -0000	[thread overview]
Message-ID: <1435464030-22372-1-git-send-email-martin.galvan@tallertechnologies.com> (raw)

From here: https://sourceware.org/ml/gdb-patches/2015-06/msg00484.html

we concluded that, as these characters don't need to be escaped for strings
wrapped inside {} braces, we can remove the unneeded backslashes.

Ok to commit?
---
 gdb/testsuite/ChangeLog   | 5 +++++
 gdb/testsuite/lib/gdb.exp | 8 +++++---
 2 files changed, 10 insertions(+), 3 deletions(-)

diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog
index 89d8e32..014132a 100644
--- a/gdb/testsuite/ChangeLog
+++ b/gdb/testsuite/ChangeLog
@@ -1,3 +1,8 @@
+2015-06-28  Martin Galvan  <martin.galvan@tallertechnologies.com>
+
+	* lib/gdb.exp (test_class_help): Remove the unneeded escaping of
+	'[' and ']' characters.
+
 2015-06-26  Keith Seitz  <keiths@redhat.com>
 	    Doug Evans  <dje@google.com>
 
diff --git a/gdb/testsuite/lib/gdb.exp b/gdb/testsuite/lib/gdb.exp
index c0e0cb1..381297a 100644
--- a/gdb/testsuite/lib/gdb.exp
+++ b/gdb/testsuite/lib/gdb.exp
@@ -4694,11 +4694,13 @@ proc help_test_raw { gdb_command expected_lines args } {
 # are regular expressions that should match the beginning of output,
 # before the list of commands in that class.  The presence of 
 # command list and standard epilogue will be tested automatically.
+# Notice that the '[' and ']' characters don't need to be escaped for strings
+# wrapped in {} braces.
 proc test_class_help { command_class expected_initial_lines args } {
     set l_stock_body {
-        "List of commands\:.*\[\r\n\]+"
-        "Type \"help\" followed by command name for full documentation\.\[\r\n\]+"
-        "Type \"apropos word\" to search for commands related to \"word\"\.[\r\n\]+"
+        "List of commands\:.*[\r\n]+"
+        "Type \"help\" followed by command name for full documentation\.[\r\n]+"
+        "Type \"apropos word\" to search for commands related to \"word\"\.[\r\n]+"
         "Command name abbreviations are allowed if unambiguous\." 
     }
     set l_entire_body [concat $expected_initial_lines $l_stock_body]
-- 
2.4.5

             reply	other threads:[~2015-06-28  4:01 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-28  4:01 Martin Galvan [this message]
2015-06-28  9:07 ` Andreas Schwab
2015-06-29 14:04   ` Doug Evans
2015-06-29 21:17     ` Martin Galvan
2015-06-29 21:43       ` Doug Evans
2015-06-30 21:28         ` Martin Galvan

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1435464030-22372-1-git-send-email-martin.galvan@tallertechnologies.com \
    --to=martin.galvan@tallertechnologies.com \
    --cc=dje@google.com \
    --cc=gdb-patches@sourceware.org \
    --cc=qiyaoltc@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).