xref: /llvm-project/lldb/test/API/commands/statistics/basic/BoxFormatter.py (revision 22144e20cbd237a432fdc4106abe3960555aff42)
1import lldb
2
3
4def summary(valobj, dict):
5    return f"[{valobj.GetChildAtIndex(0).GetValue()}]"
6
7
8def __lldb_init_module(debugger, dict):
9    typeName = "Box<.*$"
10    debugger.HandleCommand(
11        'type summary add -x "'
12        + typeName
13        + '" --python-function '
14        + f"{__name__}.summary"
15    )
16