From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 15403 invoked by alias); 9 Sep 2010 15:09:28 -0000 Received: (qmail 15390 invoked by uid 22791); 9 Sep 2010 15:09:27 -0000 X-SWARE-Spam-Status: No, hits=-1.4 required=5.0 tests=AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from imr4.ericy.com (HELO imr4.ericy.com) (198.24.6.8) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 09 Sep 2010 15:09:22 +0000 Received: from eusaamw0712.eamcs.ericsson.se ([147.117.20.181]) by imr4.ericy.com (8.14.3/8.14.3/Debian-9.1ubuntu1) with ESMTP id o89FIVa9025174; Thu, 9 Sep 2010 10:18:32 -0500 Received: from EUSAACMS0703.eamcs.ericsson.se ([169.254.1.10]) by eusaamw0712.eamcs.ericsson.se ([147.117.20.181]) with mapi; Thu, 9 Sep 2010 11:09:03 -0400 From: Marc Khouzam To: =?iso-8859-1?Q?=27Andr=E9_P=F6nitz=27?= , "'gdb@sourceware.org'" Date: Thu, 09 Sep 2010 15:09:00 -0000 Subject: RE: GDB syntax error when casting to base class Message-ID: References: <201009091559.47301.andre.poenitz@nokia.com> In-Reply-To: <201009091559.47301.andre.poenitz@nokia.com> Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 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: 2010-09/txt/msg00059.txt.bz2 > -----Original Message----- > From: Andr=E9 P=F6nitz [mailto:andre.poenitz@nokia.com]=20 > Sent: Thursday, September 09, 2010 10:00 AM > To: gdb@sourceware.org > Cc: Marc Khouzam > Subject: Re: GDB syntax error when casting to base class >=20 > On Thursday 09 September 2010 14:50:07 ext Marc Khouzam wrote: > > Hi, > >=20 > > I got an eclipse bug report that led me to a bizarre=20 > behavior from GDB. > > In the very short session below, I'm getting a syntax error=20 > when casting > > a variable to its base class. > > If I remove the constructor (see comment in the code below) > > the problem goes away. Or if I add the word 'struct', it=20 > also goes away. > >=20 > > This is causing problems in Eclipse because=20 > -var-info-path-expression > > returns the expression that causes a syntax error. > >=20 > > I tried to debug it but I ended up in c-exp.y and had to give up. > >=20 > > I was going to propose a patch that adds 'struct' to the=20 > > -var-info-path-expression output, but I didn't think that was the=20 > > greatest of solutions. Currently, this is what we are planning to=20 > > do in Eclipse to work around this problem. > > > > I can open a PR if it makes sense? >=20 > Tom mentioned the 'struct' workaround in comment #4 to > http://sourceware.org/bugzilla/show_bug.cgi?id=3D11912, so > maybe the issue is related. Yes, it looks like the same issue except that it also happens with 6.8. I've added my info to the bug. Thanks! Marc