Skip to content
Commit 05e8d194 authored by Greg Clayton's avatar Greg Clayton
Browse files

Added a new class to the lldb python module:

lldb.value()

It it designed to be given a lldb.SBValue object and it allows natural
use of a variable value:

    pt = lldb.value(lldb.frame.FindVariable("pt"))
    print pt
    print pt.x
    print pt.y

    pt = lldb.frame.FindVariable("rectangle_array")
    print rectangle_array[12]
    print rectangle_array[5].origin.x

Note that array access works just fine and works on arrays or pointers:

pt = lldb.frame.FindVariable("point_ptr")
print point_ptr[5].y

Also note that pointer child accesses are done using a "." instead of "->":

print point_ptr.x

llvm-svn: 149464
parent 7bb0067c
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment