From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6024 invoked by alias); 4 May 2006 17:32:22 -0000 Received: (qmail 6016 invoked by uid 22791); 4 May 2006 17:32:22 -0000 X-Spam-Check-By: sourceware.org Received: from wx-out-0102.google.com (HELO wx-out-0102.google.com) (66.249.82.205) by sourceware.org (qpsmtpd/0.31) with ESMTP; Thu, 04 May 2006 17:32:13 +0000 Received: by wx-out-0102.google.com with SMTP id h30so370754wxd for ; Thu, 04 May 2006 10:32:11 -0700 (PDT) Received: by 10.70.100.14 with SMTP id x14mr1000118wxb; Thu, 04 May 2006 10:32:11 -0700 (PDT) Received: by 10.70.129.13 with HTTP; Thu, 4 May 2006 10:32:11 -0700 (PDT) Message-ID: <8f2776cb0605041032g54a2a015hb4b8535d5cff5795@mail.gmail.com> Date: Thu, 04 May 2006 17:32:00 -0000 From: "Jim Blandy" To: "Nick Roberts" Subject: Re: Variable objects: references formatting Cc: "Vladimir Prus" , gdb-patches@sources.redhat.com In-Reply-To: <17497.24251.518395.25087@farnswood.snap.net.nz> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: <17497.14121.225320.477428@farnswood.snap.net.nz> <8f2776cb0605031650o1cf451bex682613fd1434a110@mail.gmail.com> <17497.24251.518395.25087@farnswood.snap.net.nz> X-Google-Sender-Auth: 9516d9cef5f2734b X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2006-05/txt/msg00048.txt.bz2 On 5/3/06, Nick Roberts wrote: > > The patch is against an older version of varobj.c, and does seem to be > > cut from a larger patch, but it applies, and given the surrounding > > code in c_value_of_variable, and the behavior of c_val_print, the > > general sense of the change seems correct. Have you tried creating > > varobjs for values that are references to structs and displaying them, > > which I think is the case actually being addressed? > > OK, if its a patch for -var-valuate-expression then perhaps the BOGUS > comment could be removed as it seems to address this issue. I read the "BOGUS" comment as referring to the fact that we have to specially trap structs and unions, instead of simply passing everything through common_val_print. I don't think this patch affects that "bogusness"; it just makes the workaround work better. (Are there any cases where common_val_print (and thus c_val_print) prints the "{...}" we need automatically for us? Or is this code the sole source of that behavior?)