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.objc/objcdecode.exp test error..


On Thu, Sep 24, 2009 at 9:03 PM, Matt Rice <ratmice@gmail.com> wrote:
> On Wed, Sep 23, 2009 at 5:53 PM, Joel Brobecker <brobecker@adacore.com> wrote:
> <snip>
>
>> ? ?(gdb) break create
>>
>> can result in numerous breakpoints being set if create just happens
>> to be the name any ObjC method. And as it turns out, the NSThread
>> class has a method called "main"...
>>
>> I really think that allowing the above shortcut is a mis-feature
>> that we should consider removing. We could possibly think about
>> introducing another syntax meaning all "create" methods in all
>> classes, if it really is needed by ObjC developers.
>

Well hmm, I'm going to propose another solution:
'set objc words-match-methods <on|off|auto>'

Here is the reason why:

the approach taken by category.diff will never be able to work 100% of
the time with pending breakpoints, and a solution for it would also
allow c-symbols to match methods, and pending breakpoints on c++
overloaded methods
c++ currently disables these by jumping out so decode_line_1 never returns,

to take that approach with objc, would basically mean disabling
pending breakpoints on all methods, which is kind of throwing the baby
out with the bath water.

auto could default to no if words-match-methods is buggy or if no objc
compilation units have loaded?


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