[lldb-dev] Inspecting local variables whose name collides with a built-in LLDB type

Enrico Granata egranata at apple.com
Wed Jul 9 10:33:05 PDT 2014


> On Jul 9, 2014, at 9:54 AM, Bobby Holley <bholley at mozilla.com> wrote:
> 
> Hi,
> 
> I use LLDB (lldb-310.2.37) to debug Firefox/Gecko. One of my biggest annoyances is that I can't seem to make it inspect a local variable called 'id' (of which we have many) because 'id' is the name of a built-in LLDB type.
> 
> (lldb) p id
> (lldb) p id.get()
> error: cannot use dot operator on a type
> error: 1 errors parsing expression
> 
> I can't seem to find a bug on this - is there one on file? More importantly, is there some escaping mechanism I can use as a workaround?
> 
> Thanks,
> bholley
> _______________________________________________
> lldb-dev mailing list
> lldb-dev at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/lldb-dev

(lldb) frame variable id

should work

You won’t be able to say

(lldb) frame variable id.get()

but I am assuming get() will access some local ivar of “id”, which you might be able to do via frame variable



More information about the lldb-dev mailing list