This is the mail archive of the gdb-patches@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: [RFC] delete gdb.cp/ambiguous.exp ?


On Tue, Aug 19, 2014 at 9:49 AM, Pedro Alves <palves@redhat.com> wrote:
> On 08/19/2014 12:23 AM, Doug Evans wrote:
>> Along the lines of dead code removal ...
>>
>> What should we do with this testcase?
>>
>> The messages it is looking for from gdb do not exist,
>
> Hmm.  These are:
>
> # X is derived from A1 and A2; both A1 and A2 have a member 'x'
> send_gdb "print x.x\n"
> gdb_expect {
>    -re "warning: x ambiguous; using X::A2::x. Use a cast to disambiguate.\r\n\\$\[0-9\]* = \[-\]*\[0-9\]*\r\n$gdb_prompt $" {
>        pass "print x.x"
>    }
>    -re "warning: x ambiguous; using X::A1::x. Use a cast to disambiguate.\r\n\\$\[0-9\]* = \[-\]*\[0-9\]*\r\n$gdb_prompt $" {
>        pass "print x.x"
>    }
>    -re ".*$gdb_prompt $" { fail "print x.x" }
>    timeout { fail "(timeout) print x.x" }
> }
>
> Actually enabling the test (removing the skip, and adding
> nowarnings), we see that indeed GDB outputs no warning:

But given the early exit the test itself is never run.
And it's been this way since at least 2003 (commit 4d9eda44f), and
longer (that commit just changed the style of the gcc test)!

I'm all for filing a bug and recording the test in the bug report.
I'm even ok with keeping the test as is.
The high order bit for me is exploring what the community wishes be
done with this kind of "dead code".


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