Skip to content
This repository was archived by the owner on Mar 8, 2020. It is now read-only.

Commit b5c7e21

Browse files
author
Juanjo Alvarez
committed
Added fixture for enums
Signed-off-by: Juanjo Alvarez <juanjo@sourced.tech>
1 parent aa49ade commit b5c7e21

57 files changed

Lines changed: 34921 additions & 25468 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

fixtures/_integration.cpp.legacy

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ CPPASTTranslationUnit {
3030
. . . Properties: {
3131
. . . . IsActive: true
3232
. . . . IsFrozen: true
33-
. . . . internalRole: XXXProp_Declarations
33+
. . . . internalRole: Prop_Declarations
3434
. . . }
3535
. . . Children: {
3636
. . . . 0: CPPASTName {
@@ -50,7 +50,7 @@ CPPASTTranslationUnit {
5050
. . . . . . IsFrozen: true
5151
. . . . . . IsQualified: false
5252
. . . . . . Name: std
53-
. . . . . . internalRole: XXXProp_QualifiedName
53+
. . . . . . internalRole: Prop_QualifiedName
5454
. . . . . }
5555
. . . . }
5656
. . . }
@@ -72,7 +72,7 @@ CPPASTTranslationUnit {
7272
. . . . IsDefaulted: false
7373
. . . . IsDeleted: false
7474
. . . . IsFrozen: true
75-
. . . . internalRole: XXXProp_Declarations
75+
. . . . internalRole: Prop_Declarations
7676
. . . }
7777
. . . Children: {
7878
. . . . 0: CPPASTSimpleDeclSpecifier {
@@ -108,7 +108,7 @@ CPPASTTranslationUnit {
108108
. . . . . . IsVolatile: false
109109
. . . . . . StorageClass: unspecified
110110
. . . . . . Type: int
111-
. . . . . . internalRole: XXXProp_DeclSpecifier
111+
. . . . . . internalRole: Prop_DeclSpecifier
112112
. . . . . }
113113
. . . . }
114114
. . . . 1: CPPASTFunctionDeclarator {
@@ -134,7 +134,7 @@ CPPASTTranslationUnit {
134134
. . . . . . IsPureVirtual: false
135135
. . . . . . IsVolatile: false
136136
. . . . . . TakesVarArgs: false
137-
. . . . . . internalRole: XXXProp_Declarator
137+
. . . . . . internalRole: Prop_Declarator
138138
. . . . . }
139139
. . . . . Children: {
140140
. . . . . . 0: CPPASTName {
@@ -154,7 +154,7 @@ CPPASTTranslationUnit {
154154
. . . . . . . . IsFrozen: true
155155
. . . . . . . . IsQualified: false
156156
. . . . . . . . Name: main
157-
. . . . . . . . internalRole: XXXProp_Name
157+
. . . . . . . . internalRole: Prop_Name
158158
. . . . . . . }
159159
. . . . . . }
160160
. . . . . }
@@ -174,7 +174,7 @@ CPPASTTranslationUnit {
174174
. . . . . Properties: {
175175
. . . . . . IsActive: true
176176
. . . . . . IsFrozen: true
177-
. . . . . . internalRole: XXXProp_Body
177+
. . . . . . internalRole: Prop_Body
178178
. . . . . }
179179
. . . . . Children: {
180180
. . . . . . 0: CPPASTExpressionStatement {
@@ -192,7 +192,7 @@ CPPASTTranslationUnit {
192192
. . . . . . . Properties: {
193193
. . . . . . . . IsActive: true
194194
. . . . . . . . IsFrozen: true
195-
. . . . . . . . internalRole: XXXProp_Statements
195+
. . . . . . . . internalRole: Prop_Statements
196196
. . . . . . . }
197197
. . . . . . . Children: {
198198
. . . . . . . . 0: CPPASTBinaryExpression {
@@ -214,7 +214,7 @@ CPPASTTranslationUnit {
214214
. . . . . . . . . . IsFrozen: true
215215
. . . . . . . . . . IsLValue: false
216216
. . . . . . . . . . Operator: left <<
217-
. . . . . . . . . . internalRole: XXXProp_Expression
217+
. . . . . . . . . . internalRole: Prop_Expression
218218
. . . . . . . . . }
219219
. . . . . . . . . Children: {
220220
. . . . . . . . . . 0: CPPASTIdExpression {
@@ -235,7 +235,7 @@ CPPASTTranslationUnit {
235235
. . . . . . . . . . . . IsActive: true
236236
. . . . . . . . . . . . IsFrozen: true
237237
. . . . . . . . . . . . IsLValue: false
238-
. . . . . . . . . . . . internalRole: XXXProp_Operand1
238+
. . . . . . . . . . . . internalRole: Prop_Operand1
239239
. . . . . . . . . . . }
240240
. . . . . . . . . . . Children: {
241241
. . . . . . . . . . . . 0: CPPASTName {
@@ -255,7 +255,7 @@ CPPASTTranslationUnit {
255255
. . . . . . . . . . . . . . IsFrozen: true
256256
. . . . . . . . . . . . . . IsQualified: false
257257
. . . . . . . . . . . . . . Name: cout
258-
. . . . . . . . . . . . . . internalRole: XXXProp_Name
258+
. . . . . . . . . . . . . . internalRole: Prop_Name
259259
. . . . . . . . . . . . . }
260260
. . . . . . . . . . . . }
261261
. . . . . . . . . . . }
@@ -279,7 +279,7 @@ CPPASTTranslationUnit {
279279
. . . . . . . . . . . . IsFrozen: true
280280
. . . . . . . . . . . . IsLValue: true
281281
. . . . . . . . . . . . LiteralValue: "Hello, World!"
282-
. . . . . . . . . . . . internalRole: XXXProp_InitOperand2
282+
. . . . . . . . . . . . internalRole: Prop_InitOperand2
283283
. . . . . . . . . . . . kind: string_literal
284284
. . . . . . . . . . . }
285285
. . . . . . . . . . }
@@ -302,7 +302,7 @@ CPPASTTranslationUnit {
302302
. . . . . . . . . . . . IsFrozen: true
303303
. . . . . . . . . . . . IsLValue: true
304304
. . . . . . . . . . . . LiteralValue: "Hello, World!"
305-
. . . . . . . . . . . . internalRole: XXXProp_Operand2
305+
. . . . . . . . . . . . internalRole: Prop_Operand2
306306
. . . . . . . . . . . . kind: string_literal
307307
. . . . . . . . . . . }
308308
. . . . . . . . . . }
@@ -325,7 +325,7 @@ CPPASTTranslationUnit {
325325
. . . . . . . Properties: {
326326
. . . . . . . . IsActive: true
327327
. . . . . . . . IsFrozen: true
328-
. . . . . . . . internalRole: XXXProp_Statements
328+
. . . . . . . . internalRole: Prop_Statements
329329
. . . . . . . }
330330
. . . . . . . Children: {
331331
. . . . . . . . 0: CPPASTLiteralExpression {
@@ -347,7 +347,7 @@ CPPASTTranslationUnit {
347347
. . . . . . . . . . IsFrozen: true
348348
. . . . . . . . . . IsLValue: false
349349
. . . . . . . . . . LiteralValue: 0
350-
. . . . . . . . . . internalRole: XXXProp_ReturnArgument
350+
. . . . . . . . . . internalRole: Prop_ReturnArgument
351351
. . . . . . . . . . kind: integer_constant
352352
. . . . . . . . . }
353353
. . . . . . . . }
@@ -370,7 +370,7 @@ CPPASTTranslationUnit {
370370
. . . . . . . . . . IsFrozen: true
371371
. . . . . . . . . . IsLValue: false
372372
. . . . . . . . . . LiteralValue: 0
373-
. . . . . . . . . . internalRole: XXXProp_ReturnValue
373+
. . . . . . . . . . internalRole: Prop_ReturnValue
374374
. . . . . . . . . . kind: integer_constant
375375
. . . . . . . . . }
376376
. . . . . . . . }

fixtures/_integration.cpp.native

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@
4545
LocOffsetEnd: 83,
4646
LocOffsetStart: 59,
4747
'Prop_Expression': {
48-
ExpressionType: "org.eclipse.cdt.internal.core.dom.parser.ProblemType@4567f35d",
48+
ExpressionType: "org.eclipse.cdt.internal.core.dom.parser.ProblemType@694abbdc",
4949
ExpressionValueCategory: "PRVALUE",
5050
IASTClass: "CPPASTBinaryExpression",
5151
IsActive: true,
@@ -67,7 +67,7 @@
6767
kind: "string_literal",
6868
},
6969
'Prop_Operand1': {
70-
ExpressionType: "org.eclipse.cdt.internal.core.dom.parser.ProblemType@4567f35d",
70+
ExpressionType: "org.eclipse.cdt.internal.core.dom.parser.ProblemType@694abbdc",
7171
ExpressionValueCategory: "PRVALUE",
7272
IASTClass: "CPPASTIdExpression",
7373
IsActive: true,

fixtures/_integration.cpp.sem.uast

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@
118118
col: 28,
119119
},
120120
},
121-
ExpressionType: "org.eclipse.cdt.internal.core.dom.parser.ProblemType@694abbdc",
121+
ExpressionType: "org.eclipse.cdt.internal.core.dom.parser.ProblemType@4567f35d",
122122
ExpressionValueCategory: "PRVALUE",
123123
IsActive: true,
124124
IsFrozen: true,
@@ -160,7 +160,7 @@
160160
col: 9,
161161
},
162162
},
163-
ExpressionType: "org.eclipse.cdt.internal.core.dom.parser.ProblemType@694abbdc",
163+
ExpressionType: "org.eclipse.cdt.internal.core.dom.parser.ProblemType@4567f35d",
164164
ExpressionValueCategory: "PRVALUE",
165165
IsActive: true,
166166
IsFrozen: true,

fixtures/_integration.cpp.uast

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@
118118
col: 28,
119119
},
120120
},
121-
ExpressionType: "org.eclipse.cdt.internal.core.dom.parser.ProblemType@a514af7",
121+
ExpressionType: "org.eclipse.cdt.internal.core.dom.parser.ProblemType@694abbdc",
122122
ExpressionValueCategory: "PRVALUE",
123123
IsActive: true,
124124
IsFrozen: true,
@@ -160,7 +160,7 @@
160160
col: 9,
161161
},
162162
},
163-
ExpressionType: "org.eclipse.cdt.internal.core.dom.parser.ProblemType@a514af7",
163+
ExpressionType: "org.eclipse.cdt.internal.core.dom.parser.ProblemType@694abbdc",
164164
ExpressionValueCategory: "PRVALUE",
165165
IsActive: true,
166166
IsFrozen: true,

fixtures/comments.cpp.native

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,14 @@
1111
FreestadingComments: [
1212
{
1313
Comment: "/* Multi line\n * comment */",
14+
IASTClass: "Comment",
1415
IsBlockComment: true,
1516
LocOffsetEnd: 79,
1617
LocOffsetStart: 52,
1718
},
1819
{
1920
Comment: "/** Unnoficial doxygen comment */",
21+
IASTClass: "Comment",
2022
IsBlockComment: true,
2123
LocOffsetEnd: 114,
2224
LocOffsetStart: 81,
@@ -28,6 +30,7 @@
2830
LeadingComments: [
2931
{
3032
Comment: "// single line comment",
33+
IASTClass: "Comment",
3134
IsBlockComment: false,
3235
LocOffsetEnd: 22,
3336
LocOffsetStart: 0,
@@ -82,6 +85,7 @@
8285
TrailingComments: [
8386
{
8487
Comment: "// single line after",
88+
IASTClass: "Comment",
8589
IsBlockComment: false,
8690
LocOffsetEnd: 50,
8791
LocOffsetStart: 30,

fixtures/comments.cpp.sem.uast

Lines changed: 56 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -32,27 +32,60 @@
3232
},
3333
},
3434
FreestadingComments: [
35-
{
35+
{ '@type': "Comment",
36+
'@role': [Unannotated],
37+
'@pos': { '@type': "uast:Positions",
38+
start: { '@type': "uast:Position",
39+
offset: 52,
40+
line: 4,
41+
col: 1,
42+
},
43+
end: { '@type': "uast:Position",
44+
offset: 79,
45+
line: 5,
46+
col: 14,
47+
},
48+
},
3649
Comment: "/* Multi line\n * comment */",
3750
IsBlockComment: true,
38-
LocOffsetEnd: 79,
39-
LocOffsetStart: 52,
4051
},
41-
{
52+
{ '@type': "Comment",
53+
'@role': [Unannotated],
54+
'@pos': { '@type': "uast:Positions",
55+
start: { '@type': "uast:Position",
56+
offset: 81,
57+
line: 7,
58+
col: 1,
59+
},
60+
end: { '@type': "uast:Position",
61+
offset: 114,
62+
line: 7,
63+
col: 34,
64+
},
65+
},
4266
Comment: "/** Unnoficial doxygen comment */",
4367
IsBlockComment: true,
44-
LocOffsetEnd: 114,
45-
LocOffsetStart: 81,
4668
},
4769
],
4870
IsActive: true,
4971
IsFrozen: true,
5072
LeadingComments: [
51-
{
73+
{ '@type': "Comment",
74+
'@role': [Unannotated],
75+
'@pos': { '@type': "uast:Positions",
76+
start: { '@type': "uast:Position",
77+
offset: 0,
78+
line: 1,
79+
col: 1,
80+
},
81+
end: { '@type': "uast:Position",
82+
offset: 22,
83+
line: 1,
84+
col: 23,
85+
},
86+
},
5287
Comment: "// single line comment",
5388
IsBlockComment: false,
54-
LocOffsetEnd: 22,
55-
LocOffsetStart: 0,
5689
},
5790
],
5891
'Prop_DeclSpecifier': { '@type': "CPPASTSimpleDeclSpecifier",
@@ -130,11 +163,22 @@
130163
},
131164
],
132165
TrailingComments: [
133-
{
166+
{ '@type': "Comment",
167+
'@role': [Unannotated],
168+
'@pos': { '@type': "uast:Positions",
169+
start: { '@type': "uast:Position",
170+
offset: 30,
171+
line: 2,
172+
col: 8,
173+
},
174+
end: { '@type': "uast:Position",
175+
offset: 50,
176+
line: 2,
177+
col: 28,
178+
},
179+
},
134180
Comment: "// single line after",
135181
IsBlockComment: false,
136-
LocOffsetEnd: 50,
137-
LocOffsetStart: 30,
138182
},
139183
],
140184
},

0 commit comments

Comments
 (0)