This is the mail archive of the gdb@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: C++ related core dump


On Thu, Nov 17, 2005 at 10:45:11AM +0100, Mark Kettenis wrote:
> No, no, you misread that bit above.  antennac is an instance of class
> ROScalarColumn<int>.  So antennac(0) *is* an invocation of operator().

Oh.  Then what type IS the fsym?

> > GDB does _not_ support calling constructors, though.  This is a bit
> > tricky.
> > 
> > > Regardless of properly invoking operator(), we should do something
> > > about this crash.  Can we do something better than the attached patch?
> > 
> > > -      func_name	= cp_func_name (qualified_name);
> > > +      if (qualified_name)
> > > +	func_name = cp_func_name (qualified_name);
> > 
> > Return earlier if fsym is not a function?  Or this seems reasonable, to
> > avoid the crash.
> 
> Hmm the comment just below mentions C-style functions.  Doesn't
> SYMBOL_CPLUS_DEMANGLED_NAME (fsym) return NULL for C-style functions
> too?  In that case I think my patch is indeed the right approach.

Probably so, but let's work out what's going on first.

-- 
Daniel Jacobowitz
CodeSourcery, LLC


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]