From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mailsec108.isp.belgacom.be (mailsec108.isp.belgacom.be [195.238.20.104]) by sourceware.org (Postfix) with ESMTPS id 1AD563858D35 for ; Tue, 16 Apr 2024 16:57:46 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 1AD563858D35 Authentication-Results: sourceware.org; dmarc=pass (p=quarantine dis=none) header.from=skynet.be Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=skynet.be ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 1AD563858D35 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=195.238.20.104 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1713286669; cv=none; b=ujCYvi2wYChWDiu6xgYqwxD6dQStW8SiESiW1x3uQH7FsMZUBBfqsvkV36i61DG6LEJ9p0OqXXKUWR2k3iq44sbYi/Xa3QIFKR9YNe7RMOgZRZjkgAJKFQD9+GsTzyE4Ri/DD30sFBlhDv7aiAPJvRyjluOQ8jjbpc1O7yQmq7g= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1713286669; c=relaxed/simple; bh=ngZU27XqIHO31BFdA5xpWD6N8VHq4rw3jTnjXWGUR0I=; h=DKIM-Signature:Message-ID:Subject:From:To:Date:MIME-Version; b=vMjYEXSn1c1VweSoAa/Vu1ctUEMJF7XJsHii9opm8dh3w6y1SwxcGT2eoxUEJZZjx+emIdXHZS5QVCPoFgID71Y3zWz4CFSva4A6SmotBvd87JYp2be6nnMjB8KmXeF+tZx9lXuI7xRo3YKtypnnhPN8i0Jx4Xosxnnom1voN6U= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=skynet.be; i=@skynet.be; q=dns/txt; s=rmail; t=1713286666; x=1744822666; h=message-id:subject:from:to:cc:date:in-reply-to: references:content-transfer-encoding:mime-version; bh=ngZU27XqIHO31BFdA5xpWD6N8VHq4rw3jTnjXWGUR0I=; b=dzJFpmUecuIeoCSuab2YWFjYLmqgLOZSmfWLTCb8P3AqljO7wR1OPJl9 unWehQN3SqfUurqTdHpdLdr0Fii5Kw2avRN8TLciginmaeOrjKjNH5fZO A7QLM7wgGysZLkXzdblaU224Wj50i87HcC173JuAsqY1CCar31J8XQYSH I=; X-CSE-ConnectionGUID: xhuj7znrTS2p7j042KLYuw== X-CSE-MsgGUID: OdITkgTpSZGeyEifZM+V/g== X-ExtLoop: 1 X-ThreatScanner-Verdict: Negative X-IPAS-Result: =?us-ascii?q?A2EbAQB2rR5m/1uGgG0NTYEJCYFGhSCEVpFoA5wygVaBf?= =?us-ascii?q?g8BAQEBAQEBAQEJRAQBAYUGAogcJzYHDgECBAEBAQEDAgMBAQEBAQEBAQYBA?= =?us-ascii?q?QEFAQEBAQEBBgQBAQECgRmFL4MyAYN3AQEBAQMjVhAJAhQBAwICJgICSAENB?= =?us-ascii?q?gESnUObOnqBMoEBhHnZNoFqgRouiC4BgVmEI4RANoFVRIQHOD6EQ4NbgmgEl?= =?us-ascii?q?SaCYoNxhh4JS30cA1khEwFVEyAPDBoCGxQNJCMCKT4DCQoQAhYDHQkLBDARC?= =?us-ascii?q?QsmAyoGNgISDAYGBlsgFgkEIwMIBAMQQAMgcBEDBBoECwd1gXyBPQQTRAIBE?= =?us-ascii?q?IEyhT2EWAyBHYI9gUEDCimEM0txhB2BTAYSA0QdQAMLbT01FBsGIgGhTB5RC?= =?us-ascii?q?IEkBUAIBCwINRArkjOyVTQHhBaBWwYMn1ozqjSYYiCoZYFrBYIKbYM6Uiipf?= =?us-ascii?q?HY7AgcBCgEBAwmJIoFIAQE?= IronPort-PHdr: A9a23:hNU3+xTHhtyLMbIHuph/WXbB+tpsolKYAWYlg6HPa5pwe6iut67vI FbYra00ygOTDMOCtKwP17aempujcFJDyK7JiGoFfp1IWk1NouQttCtkLei7TGbWF7rUVRE8B 9lIT1R//nu2YgB/Ecf6YEDO8DXptWZBUhrwOh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ED3uR7bPRoSK0fykONSkIaCsLRAAC5p/prenfky7yczqqK4bt5vWdJN066 2niQPQW71nYsSLHO2hXM7wKb/JAa6UlljII2zg= IronPort-HdrOrdr: A9a23:bqAtlqOUYxkY0cBcTsqjsMiBIKoaSvp037Dk7S9MoHtuA66lfq GV7ZcmPHDP5gr5NEtMpTnEAsi9qBDnhPpICOsqVotKNTOO0FdAbrsD0WKI+Vfd8kPFmtK1mZ 0QFpRDNA== X-Talos-CUID: =?us-ascii?q?9a23=3ANpMvSWh7LnmNRk3agVvwJHlnrDJuYn3AzijCJVW?= =?us-ascii?q?EMjxxF7/NFQWz3JJ5jJ87?= X-Talos-MUID: 9a23:9vHGLwkZbV/LHfWYr6EXdnpFOOZU4KuSEHs/vpgXlsiKBwkzBXCS2WE= X-IronPort-Anti-Spam-Filtered: true X-ProximusIPWarmup: true Received: from 91.134-128-109.adsl-dyn.isp.belgacom.be (HELO [192.168.1.19]) ([109.128.134.91]) by relay.proximus.be with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 16 Apr 2024 18:57:44 +0200 Message-ID: Subject: Re: [PATCH] Fix whitespace in "help set inferior-tty" From: Philippe Waroquiers To: Eli Zaretskii , Simon Marchi Cc: gdb-patches@sourceware.org Date: Tue, 16 Apr 2024 18:57:43 +0200 In-Reply-To: <86v84hi8q4.fsf@gnu.org> References: <86wmoxict8.fsf@gnu.org> <0dfc55f1-3ce7-4fa9-af3a-f322df320b9b@simark.ca> <86v84hi8q4.fsf@gnu.org> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.46.4-2 MIME-Version: 1.0 X-Spam-Status: No, score=-10.1 required=5.0 tests=BAYES_00,BODY_8BITS,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,GIT_PATCH_0,RCVD_IN_DNSWL_LOW,SPF_HELO_PASS,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: Note that gdb/unittests/command-def-selftests.c checks various invariants a= bout the command doc strings. We might add there a new invariant that there is no white space before a LF and no space at the end of doc string. This should avoid such problems to re-appear in the future. Thanks Philippe On Tue, 2024-04-16 at 19:16 +0300, Eli Zaretskii wrote: > > Date: Tue, 16 Apr 2024 11:45:06 -0400 > > From: Simon Marchi > >=20 > >=20 > >=20 > > On 2024-04-16 10:48, Eli Zaretskii wrote: > > > Hi, > > >=20 > > > I've noticed that doc strings of "set inferior-tty" and "set cwd" hav= e > > > some excess whitespace, which makes them display with unexpected > > > indentation, at least in a Windows command prompt window. The patch > > > below fixes that. OK to install? > >=20 > > I see the same problem. > >=20 > > grepping around, I think I found more instances of the same problem: > >=20 > > linux-nat.c:4704:Set debugging of GNU/Linux native target."), _(" = \ > > linux-nat.c:4705:Show debugging of GNU/Linux native target."), _(" = \ > > riscv-tdep.c:4824:Set debugger's use of compressed breakpoints."), _(" = \ > > top.c:2270:Set whether GDB should start up quietly."), _(" = \ > >=20 > > Can you confirm and include them in your patch? >=20 > Confirmed and installed as below. Thanks. >=20 > commit 6a2dbb742dc5aa18bc7995f7af55fb6e74c3ae4a > Author: Eli Zaretskii > AuthorDate: Tue Apr 16 19:13:39 2024 +0300 > Commit: Eli Zaretskii > CommitDate: Tue Apr 16 19:13:39 2024 +0300 >=20 > =C2=A0=C2=A0=C2=A0=C2=A0Remove excess whitespace from doc strings of some= commands > =C2=A0=C2=A0=C2=A0=C2=A0 > =C2=A0=C2=A0=C2=A0=C2=A0I've noticed that doc strings of some commands, l= ike "set cwd" > =C2=A0=C2=A0=C2=A0=C2=A0and "set inferior-tty", have some excess whitesp= ace, which > =C2=A0=C2=A0=C2=A0=C2=A0makes them display with unexpected indentation, a= t least in a > =C2=A0=C2=A0=C2=A0=C2=A0Windows command prompt window. This patch fixes = that. > =C2=A0=C2=A0=C2=A0=C2=A0 > =C2=A0=C2=A0=C2=A0=C2=A0* gdb/linux-nat.c (_initialize_linux_nat): > =C2=A0=C2=A0=C2=A0=C2=A0* gdb/riscv-tdep.c (riscv_insn): > =C2=A0=C2=A0=C2=A0=C2=A0* gdb/top.c (quit_force): > =C2=A0=C2=A0=C2=A0=C2=A0* gdb/infcmd.c (_initialize_infcmd): Remove exces= s whitespace. >=20 > diff --git a/gdb/infcmd.c b/gdb/infcmd.c > index 600c90c..10a964a 100644 > --- a/gdb/infcmd.c > +++ b/gdb/infcmd.c > @@ -3093,10 +3093,10 @@ _initialize_infcmd () > =C2=A0=C2=A0=C2=A0/* Add the filename of the terminal connected to inferi= or I/O. */ > =C2=A0=C2=A0=C2=A0auto tty_set_show > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=3D add_setshow_optional_filename_cmd ("inf= erior-tty", class_run, _("\ > -Set terminal for future runs of program being debugged."), _(" \ > -Show terminal for future runs of program being debugged."), _(" \ > -Usage: set inferior-tty [TTY]\n\n \ > -If TTY is omitted, the default behavior of using the same terminal as GD= B\n \ > +Set terminal for future runs of program being debugged."), _("\ > +Show terminal for future runs of program being debugged."), _("\ > +Usage: set inferior-tty [TTY]\n\n\ > +If TTY is omitted, the default behavior of using the same terminal as GD= B\n\ > =C2=A0is restored."), > =C2=A0 set_tty_value, > =C2=A0 get_tty_value, > @@ -3117,8 +3117,8 @@ Follow this command with any number of args, to be = passed to the > program."), > =C2=A0 > =C2=A0=C2=A0=C2=A0auto cwd_set_show > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=3D add_setshow_string_noescape_cmd ("cwd",= class_run, _("\ > -Set the current working directory to be used when the inferior is starte= d.\n \ > -Changing this setting does not have any effect on inferiors that are\n \ > +Set the current working directory to be used when the inferior is starte= d.\n\ > +Changing this setting does not have any effect on inferiors that are\n\ > =C2=A0already running."), > =C2=A0 _("\ > =C2=A0Show the current working directory that is used when the inferior i= s started."), > diff --git a/gdb/linux-nat.c b/gdb/linux-nat.c > index 2602e1f..42051f2 100644 > --- a/gdb/linux-nat.c > +++ b/gdb/linux-nat.c > @@ -4701,8 +4701,8 @@ _initialize_linux_nat () > =C2=A0{ > =C2=A0=C2=A0=C2=A0add_setshow_boolean_cmd ("linux-nat", class_maintenance= , > =C2=A0 &debug_linux_nat, _("\ > -Set debugging of GNU/Linux native target."), _(" \ > -Show debugging of GNU/Linux native target."), _(" \ > +Set debugging of GNU/Linux native target."), _("\ > +Show debugging of GNU/Linux native target."), _("\ > =C2=A0When on, print debug messages relating to the GNU/Linux native targ= et."), > =C2=A0 nullptr, > =C2=A0 show_debug_linux_nat, > diff --git a/gdb/riscv-tdep.c b/gdb/riscv-tdep.c > index f86a379..fe4da1a 100644 > --- a/gdb/riscv-tdep.c > +++ b/gdb/riscv-tdep.c > @@ -4821,7 +4821,7 @@ initialisation process."), > =C2=A0=C2=A0=C2=A0add_setshow_auto_boolean_cmd ("use-compressed-breakpoin= ts", no_class, > =C2=A0 &use_compressed_breakpoints, > =C2=A0 _("\ > -Set debugger's use of compressed breakpoints."), _(" \ > +Set debugger's use of compressed breakpoints."), _("\ > =C2=A0Show debugger's use of compressed breakpoints."), _("\ > =C2=A0Debugging compressed code requires compressed breakpoints to be use= d. If\n\ > =C2=A0left to 'auto' then gdb will use them if the existing instruction i= s a\n\ > diff --git a/gdb/top.c b/gdb/top.c > index 6e9df41..d01a0c2 100644 > --- a/gdb/top.c > +++ b/gdb/top.c > @@ -2267,7 +2267,7 @@ input settings."), > =C2=A0 > =C2=A0=C2=A0=C2=A0add_setshow_boolean_cmd ("startup-quietly", class_suppo= rt, > =C2=A0 &startup_quiet, _("\ > -Set whether GDB should start up quietly."), _(" \ > +Set whether GDB should start up quietly."), _("\ > =C2=A0Show whether GDB should start up quietly."), _("\ > =C2=A0This setting will not affect the current session. Instead this com= mand\n\ > =C2=A0should be added to the .gdbearlyinit file in the users home directo= ry to\n\