This is the mail archive of the
mailing list for the GDB project.
Re: [RFC] const qualifiers in gdb.c++/method.exp
- From: Michael Elizabeth Chastain <mec at shout dot net>
- To: drow at mvista dot com
- Cc: fnf at redhat dot com, gdb-patches at sources dot redhat dot com
- Date: Thu, 10 Jan 2002 09:07:18 -0600
- Subject: Re: [RFC] const qualifiers in gdb.c++/method.exp
Daniel Jacobowitz writes:
> First of all, as best as I can tell, GCC simply doesn't support the
> stabs extensions for const and volatile. Rather than accepting this,
> we should detect it and mark them XFAILS. I would prefer to XFAIL
> based on debug info type and compiler rather than on result - if we lose the
> DWARF-2 const tag in a bug some day, it should start FAILing, not
I would prefer to FAIL rather than XFAIL. However, I accept XFAIL in
this situation, because the bug does not hurt users very much and our
chances of getting the compiler fixed are low.
setup_xfail_format is the function to use here. See gdb.c++/templates.exp
for an example. Note that the caller must call get_debug_format first.
mec> "A * const"
mec> native i686-pc-linux-gnu, gcc 3.0.2, -gdwarf-2
mec> native i686-pc-linux-gnu, gcc HEAD, -gdwarf-2
mec> native i686-pc-linux-gnu, gcc gcc-3_0-branch, -gdwarf-2
mec> "const A * const"
mec> native i686-pc-linux-gnu, gcc 2.95.3, -gdwarf-2
mec> The first seven of these are wrong. The type needs to have a "const A *"
mec> in it, rather than an "A *".
drow> That we lost this const is very interesting. It is present in the
drow> dwarf-2 information without a doubt. What version of GDB are you
drow> actually using to test this?
This is a recent CVS pull of gdb HEAD:
Checkout begin: Sat Dec 22 18:12:43 PST 2001
Checkout end: Sat Dec 22 20:08:47 PST 2001
Hmmm, that's not all that recent. :(