delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2003/05/07/15:22:12

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
X-Authentication-Warning: slinky.cs.nyu.edu: pechtcha owned process doing -bs
Date: Wed, 7 May 2003 15:01:55 -0400 (EDT)
From: Igor Pechtchanski <pechtcha AT cs DOT nyu DOT edu>
Reply-To: cygwin AT cygwin DOT com
To: "Julin, Joshua" <joshua DOT julin AT lmco DOT com>
cc: cygwin AT cygwin DOT com
Subject: RE: Cygwin-gdb can't find linker symbol for virtual table
In-Reply-To: <3888FB26DD0ACF43B7D763789F84289629F341@EMSS03M13.us.lmco.com>
Message-ID: <Pine.GSO.4.44.0305071500030.3212-100000@slinky.cs.nyu.edu>
Importance: Normal
MIME-Version: 1.0

Josh,

I can confirm the below.  It actually occurs whenever Object has any
virtual function (doesn't have to be the destructor).  It also occurs when
gcc is given a "-ggdb" option instead of "-g"...
	Igor

On Wed, 7 May 2003, Julin, Joshua wrote:

> I've verified that this problem occurs on multiple cygwin installations.
> One of them was a brand new installation.
>
> A summary of the problem:
> Cygwin-gdb doesn't handle classes with virtual destructors properly.
> It prints out a warning "can't find linker symbol for virtual table"
> whenever a member variable is printed.
> I've verified that this problem does NOT occur on linux.
> This problem causes havoc when using insight.
>
> How to recreate the problem in 3 easy steps:
> ############# step 1: create josh.cpp  ###############
> class Object
> {
> public:
>     int x;
>     virtual ~Object() { }
> };
> int main()
> {
>     Object * obj = new Object;
> }
>
> ############# step 2: build josh.cpp  ###############
> g++ -g -o josh josh.cpp
>
> ############# step 3: run gdb  ######################
> gdb josh
> b main
> r
> n
> p obj->x
>
> #####################################################
> gdb will generate this warning: (which it shouldn't)
> warning: can't find linker symbol for virtual table for `Object' value
>
> Thanks for any help,
> Josh

-- 
				http://cs.nyu.edu/~pechtcha/
      |\      _,,,---,,_		pechtcha AT cs DOT nyu DOT edu
ZZZzz /,`.-'`'    -.  ;-;;,_		igor AT watson DOT ibm DOT com
     |,4-  ) )-,_. ,\ (  `'-'		Igor Pechtchanski
    '---''(_/--'  `-'\_) fL	a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

Knowledge is an unending adventure at the edge of uncertainty.
  -- Leto II


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019