This is the mail archive of the gdb-patches@sources.redhat.com 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: [RFA] parse and eval breakpoint conditions with correct language


I think the correct behavior is to always re-parse the breakpoint in
the same language it was parsed with the first time.  If the user
liked how the breakpoint was interpreted the first time, then that's
what they meant.

We try to record that language in b->language, and
breakpoint_re_set_one tries to make sure that's the language used, by
calling set_language before re-parsing the breakpoint's line spec.
But the bug, it seems to me, is that breakpoint_re_set_one should also
set language_mode to language_mode_manual for that call to
decode_line_1, since it doesn't want any language_mode_auto-ish
language inference to mess things up.  That's what's happening now, if
I understand the misbehavior you've described.

Of course, the mode must be language_mode_auto when we re-parse any
breakpoint condition expressions or watchpoint expressions.  Both of
those expressions have blocks to use for context, and we want to use
their languages.


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