File tree Expand file tree Collapse file tree 3 files changed +34
-0
lines changed
lldb/test/API/functionalities/data-formatter/embedded-summary Expand file tree Collapse file tree 3 files changed +34
-0
lines changed Original file line number Diff line number Diff line change
1
+ C_SOURCES := main.c
2
+ include Makefile.rules
Original file line number Diff line number Diff line change
1
+ import lldb
2
+ from lldbsuite .test .lldbtest import *
3
+ from lldbsuite .test import lldbutil
4
+
5
+
6
+ class TestCase (TestBase ):
7
+ def test (self ):
8
+ self .build ()
9
+ lldbutil .run_to_source_breakpoint (self , "break here" , lldb .SBFileSpec ("main.c" ))
10
+ self .expect ("v player" , substrs = ['"Dirk" (41)' ])
Original file line number Diff line number Diff line change
1
+ #include <stdio.h>
2
+
3
+ struct Player {
4
+ char * name ;
5
+ int number ;
6
+ };
7
+
8
+ __attribute__((used , section ("__DATA_CONST,__lldbsummaries" ))) unsigned char
9
+ _Movie_type_summary [] = "\x01" // version
10
+ "\x25" // record size
11
+ "\x07" // type name size
12
+ "Player\0" // type name
13
+ "\x1c" // summary string size
14
+ "${var.name} (${var.number})" ; // summary string
15
+
16
+ int main () {
17
+ struct Player player ;
18
+ player .name = "Dirk" ;
19
+ player .number = 41 ;
20
+ puts ("break here" );
21
+ return 0 ;
22
+ }
You can’t perform that action at this time.
0 commit comments