From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 28687 invoked by alias); 5 Apr 2012 16:15:20 -0000 Received: (qmail 28669 invoked by uid 22791); 5 Apr 2012 16:15:16 -0000 X-SWARE-Spam-Status: No, hits=-2.0 required=5.0 tests=AWL,BAYES_00,KHOP_THREADED,RCVD_IN_DNSWL_NONE,RCVD_IN_HOSTKARMA_NO,SPF_SOFTFAIL X-Spam-Check-By: sourceware.org Received: from mtaout22.012.net.il (HELO mtaout22.012.net.il) (80.179.55.172) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 05 Apr 2012 16:15:03 +0000 Received: from conversion-daemon.a-mtaout22.012.net.il by a-mtaout22.012.net.il (HyperSendmail v2007.08) id <0M2000E00L3OQ600@a-mtaout22.012.net.il> for gdb-patches@sourceware.org; Thu, 05 Apr 2012 19:14:48 +0300 (IDT) Received: from HOME-C4E4A596F7 ([84.229.252.114]) by a-mtaout22.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0M2000ECOL4L45D0@a-mtaout22.012.net.il>; Thu, 05 Apr 2012 19:14:46 +0300 (IDT) Date: Thu, 05 Apr 2012 16:15:00 -0000 From: Eli Zaretskii Subject: Re: [patch#2 3/6] set auto-load local-gdbinit warn-and-* In-reply-to: <20120403183311.GB13483@host2.jankratochvil.net> To: Jan Kratochvil Cc: gdb-patches@sourceware.org Reply-to: Eli Zaretskii Message-id: <83ty0yb1fc.fsf@gnu.org> References: <20120329091258.GD25449@host2.jankratochvil.net> <83hax61rey.fsf@gnu.org> <20120403183311.GB13483@host2.jankratochvil.net> X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2012-04/txt/msg00068.txt.bz2 > Date: Tue, 3 Apr 2012 20:33:11 +0200 > From: Jan Kratochvil > Cc: gdb-patches@sourceware.org > > > > +This feature is deprecated, please use @ref{objfile-gdb.rc file} instead; > > > > "objfile" should be in @var, and it should explain what is "objfile". > > Added: > > This feature is deprecated, please use @ref{@var{objfile}-gdb.gdb file} > instead. The canned sequence of commands will be then specific for loaded > @var{objfile}---typically the main executable---after converting an init file in > the current directory into the @var{objfile}-gdb.gdb file.. Sorry, the @var inside @ref is wrong, please revert that part. > > > gdb-scripts: Canned sequences of commands auto-loading is on. > > > libthread-db: Inferior specific libthread_db auto-loading is on. > > > -local-gdbinit: Current directory .gdbinit script auto-loading is on. > > > +local-gdbinit: Current directory .gdbinit script auto-loading is yes. > > > > Why "yes"? > > parse_binary_operation accepts any of 'on', '1', 'yes' or 'enable' (and sure > off/0/no/disable). It then displays the boolean only as "on" and "off". But this hunk changes "on" into "yes", which is not what you seem to say will happen. Did I understand correctly that GDB will print "on"? > Somehow it seems more appropriate for these auto-loading settings to use > yes/no instead of on/off. This is also why I use yes/no in the documentation. > When I added the warning option I had to choose only one pair, therefore > I chose yes/no. But this means the default displayed boolean values are new > yes/no (and not on/off). It also means it no longer accepts the alternative > words on/1/enable (and off/0/disable); but that is not a real regression when > the setting never existed before this patchset. > > There are two possibilities: > * Introduce new option some "set local-gdbinit-warning " as > suggested by Doug IIUC and technically keep everything boolean. > * Switch the words used in documentation from yes/no to on/off, therefore > also make the switch on/off/warn-and-on/warn-and-off. Whatever we do, I think these options should behave consistently.