From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27303 invoked by alias); 9 Sep 2010 14:00:21 -0000 Received: (qmail 27289 invoked by uid 22791); 9 Sep 2010 14:00:19 -0000 X-SWARE-Spam-Status: No, hits=-2.0 required=5.0 tests=AWL,BAYES_00,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from smtp.nokia.com (HELO mgw-mx03.nokia.com) (192.100.122.230) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 09 Sep 2010 14:00:08 +0000 Received: from esebh106.NOE.Nokia.com (esebh106.ntc.nokia.com [172.21.138.213]) by mgw-mx03.nokia.com (Switch-3.3.3/Switch-3.3.3) with ESMTP id o89DxvOu008148; Thu, 9 Sep 2010 17:00:03 +0300 Received: from esebh102.NOE.Nokia.com ([172.21.138.183]) by esebh106.NOE.Nokia.com with Microsoft SMTPSVC(6.0.3790.4675); Thu, 9 Sep 2010 16:59:54 +0300 Received: from mgw-da02.ext.nokia.com ([147.243.128.26]) by esebh102.NOE.Nokia.com over TLS secured channel with Microsoft SMTPSVC(6.0.3790.4675); Thu, 9 Sep 2010 16:59:53 +0300 Received: from gar.localnet (berwst16747.europe.nokia.com [172.25.167.47]) by mgw-da02.ext.nokia.com (Switch-3.3.3/Switch-3.3.3) with ESMTP id o89Dxpr3016429; Thu, 9 Sep 2010 16:59:52 +0300 From: =?iso-8859-1?q?Andr=E9_P=F6nitz?= To: gdb@sourceware.org Subject: Re: GDB syntax error when casting to base class Date: Thu, 09 Sep 2010 14:00:00 -0000 User-Agent: KMail/1.13.2 (Linux/2.6.32-21-generic; KDE/4.4.2; i686; ; ) Cc: ext Marc Khouzam References: In-Reply-To: MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <201009091559.47301.andre.poenitz@nokia.com> X-Nokia-AV: Clean 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/msg00056.txt.bz2 On Thursday 09 September 2010 14:50:07 ext Marc Khouzam wrote: > Hi, > > I got an eclipse bug report that led me to a bizarre behavior from GDB. > In the very short session below, I'm getting a syntax error 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 also goes away. > > This is causing problems in Eclipse because -var-info-path-expression > returns the expression that causes a syntax error. > > I tried to debug it but I ended up in c-exp.y and had to give up. > > I was going to propose a patch that adds 'struct' to the > -var-info-path-expression output, but I didn't think that was the > greatest of solutions. Currently, this is what we are planning to > do in Eclipse to work around this problem. > > I can open a PR if it makes sense? Tom mentioned the 'struct' workaround in comment #4 to http://sourceware.org/bugzilla/show_bug.cgi?id=11912, so maybe the issue is related. Andre'