[Lldb-commits] [PATCH] find global by regex in SBTarget

jingham at apple.com jingham at apple.com
Fri Sep 19 11:55:25 PDT 2014


> On Sep 19, 2014, at 11:50 AM, Carlo Kok <ck at remobjects.com> wrote:
> 
> On Fri, 19 Sep 2014 20:18:51 +0200, <jingham at apple.com> wrote:
> 
>> I think the enum you added goes in "lldb-enumerations.h" not in SBTarget.h.
> 
> Ah yes.
>> 
>> Also, I wouldn't use the regex match for the straight match, since that is much less efficient than the ConstString ==, which is just a pointer compare.  In the fullness of time, we would retire the version that doesn't take a MatchType, so we don't want that version to be less efficient.
> 
> Done.
> 
>> Also, again, don't forget to add the new definition from SBTarget.h to SBTarget.i or the new API won't be available in Python.
> 
> 
> Ah yes, forgot to include that file in the patch. I couldn't file a .i for the enumerations though, I'm not familiar enough with swig to know for sure, but that might get pulled in automatically?
> 
> 

That's right, they get pulled in from lldb-enumerations.h.  The reason for the .i files is that that allow us to add Python specific goo - properties & iterators - to the interface.  No need to do that for the enumerations.

This looks fine, and useful, thanks.

Jim


> -- 
> Carlo Kok
> RemObjects Software<find-globals-by-regex3.patch>




More information about the lldb-commits mailing list