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: GDB/MI interactive capability?


On Sun, Apr 26, 2015 at 11:40 AM, Vladimir Prus <vladimir.prus@gmail.com> wrote:
> On 04/22/2015 10:25 PM, Joel Brobecker wrote:

>> Another idea, which might be easier to implement, would be to use
>> a two-step approach where the first step is to return an error
>> that shows the various choices the user can choose, have the IDE
>> use that to query the user, and then have the IDE resubmit the
>> expression evaluation, this time with the choice given by the user.
>
>
> That would work just fine, I think. GDB can report the ambiguities it finds,
> and the frontend can resubmit the expression with appropriate syntax to
> disambiguate.
> I don't know whether there's appropriate syntax for Ada, in C++ a cast to
> appropriate
> type is sometimes used to select the right function, e.g.:
>
>         static_cast<void (C::*)(int)>(&C::foo)
>
> is the standard example. The downside is that GDB might have to know a bit
> more about
> language than now, or a special syntax might have to be introduced.

I think it might work that instead of sending a list of stateful
numbers, it instead sent a list of explicit linespecs that can be sent
back to gdb
I'm not entirely sure (but it seems reasonable) that explicit
linespecs might avoid the ambiguity of sending a linespec to the
client which can lead to things like PR 8535


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