github.com/Konstantin8105/c4go@v0.0.0-20240505174241-768bb1c65a51/ast/cxx_constructor_decl_test.go (about) 1 package ast 2 3 import ( 4 "testing" 5 ) 6 7 func TestCXXConstructorDecl(t *testing.T) { 8 nodes := map[string]Node{ 9 `0x2fbf910 <line:3:7> col:7 implicit used person 'void (void) throw()' inline`: &CXXConstructorDecl{ 10 Addr: 0x2fbf910, 11 Pos: NewPositionFromString("line:3:7"), 12 Position2: "col:7", 13 IsImplicit: true, 14 IsUsed: true, 15 Type: "person", 16 Type2: "void (void) throw()", 17 IsInline: true, 18 Other: "", 19 ChildNodes: []Node{}, 20 }, 21 `0x343dff8 parent 0x3475f10 prev 0x34761e0 <line:28:1, line:31:1> line:28:12 used Rectangle 'void (void)'`: &CXXConstructorDecl{ 22 Addr: 0x343dff8, 23 Parent: "0x3475f10", 24 Prev: "0x34761e0", 25 Pos: NewPositionFromString("line:28:1, line:31:1"), 26 Position2: "line:28:12", 27 IsImplicit: false, 28 IsUsed: true, 29 Type: "Rectangle", 30 Type2: "void (void)", 31 IsInline: false, 32 Other: "", 33 ChildNodes: []Node{}, 34 }, 35 } 36 37 runNodeTests(t, nodes) 38 }