ladybird/Userland/Libraries/LibCpp/Tests/parser/array-initialization.ast
iyush ac435f914c LibCpp: Support for parsing c-style fixed arrays (arr[2])
Also adds tests for finding declaration of arrays inside
CppComprehension which requires proper parsing for passing.

Side-effect of this patch: if we ctrl+click on array variables, it
should jump to the correct declaration inside HackStudio.
2023-04-26 09:40:25 +01:00

19 lines
381 B
Text

TranslationUnit[0:0->2:0]
FunctionDeclaration[0:0->2:0]
NamedType[0:0->0:3]
void
foo
(
)
FunctionDefinition[0:11->2:0]
{
VariableDeclaration[1:4->1:20]
NamedType[1:4->1:6]
int
x
BracedInitList[1:15->1:20]
NumericLiteral[1:16->1:16]
1
NumericLiteral[1:18->1:18]
2
}