Add a (Python only) lldb.SBSyntheticValueProvider class to our API surface

On a suggestion from Jim Ingham, this class allows you to very easily define synthetic child providers that return a synthetic value (in the sense of r219330), but no children

Also, document this new feature in our www docs

llvm-svn: 219337
This commit is contained in:
Enrico Granata
2014-10-08 20:10:09 +00:00
parent f9e8721564
commit 8387e2fafe
2 changed files with 29 additions and 0 deletions

View File

@@ -1047,3 +1047,27 @@ class value(object):
def __neq__(self, other):
return not self.__eq__(other)
%}
%pythoncode %{
class SBSyntheticValueProvider(object):
def __init__(self,valobj):
pass
def num_children(self):
return 0
def get_child_index(self,name):
return None
def get_child_at_index(self,idx):
return None
def update(self):
pass
def has_children(self):
return False
%}