From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 14123 invoked by alias); 11 Jan 2008 22:26:14 -0000 Received: (qmail 14115 invoked by uid 22791); 11 Jan 2008 22:26:14 -0000 X-Spam-Check-By: sourceware.org Received: from viper.snap.net.nz (HELO viper.snap.net.nz) (202.37.101.8) by sourceware.org (qpsmtpd/0.31) with ESMTP; Fri, 11 Jan 2008 22:25:48 +0000 Received: from kahikatea.snap.net.nz (157.60.255.123.dynamic.snap.net.nz [123.255.60.157]) by viper.snap.net.nz (Postfix) with ESMTP id A51D33DA036; Sat, 12 Jan 2008 11:25:40 +1300 (NZDT) Received: by kahikatea.snap.net.nz (Postfix, from userid 1000) id 83EF58FC6D; Sat, 12 Jan 2008 11:25:35 +1300 (NZDT) From: Nick Roberts MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <18311.60638.724524.220449@kahikatea.snap.net.nz> Date: Fri, 11 Jan 2008 22:26:00 -0000 To: "Marc Khouzam" Cc: Subject: RE: Re: -var-update using formatted value In-Reply-To: <6D19CA8D71C89C43A057926FE0D4ADAA04290E1B@ecamlmw720.eamcs.ericsson.se> References: <6D19CA8D71C89C43A057926FE0D4ADAA04290E1B@ecamlmw720.eamcs.ericsson.se> X-Mailer: VM 7.19 under Emacs 23.0.50.27 X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2008-01/txt/msg00076.txt.bz2 > I was trying to understand why the new behaviour for var-udpate, but I > haven't figured out why a front-end would benefit from having -var-update > indicate that a variable object has changed if only its printed value is > different but not its actual content. My logic for making the change was that changes in string values were only detected if their first character changed. For example the change "GNU" to GDB": strcpy (fred, "GNU"); strcpy (fred, "GDB"); $4 = 0x804a018 "GNU" $5 = 0x804a018 "GDB" did not get picked up by -var-update. Clearly I didn't consider your case. I notice that: (gdb) p 11 $1 = 11 (gdb) p/x 11 $2 = 0xb (gdb) p/o 11 $3 = 013 (gdb) p/t 11 $6 = 1011 hexadecimal and octal outputs are distinguished by a prefix but the binary output isn't. In Eclipse how does the user know if he is looking at a binary or decimal value? I guess there's no accepted convention for binary numbers, but would it be sensible for GDB to prefix their output in some way? , e.g., (gdb) p/t 11 $6 = b1011 -- Nick http://www.inet.net.nz/~nickrob