Files
langkit/testsuite/tests/python_api/array-struct-array/expected_concrete_syntax.lkt
Pierre-Marie de Rodat 7698a8d111 dsl_unparse: remove spurious line break in grammars
For GitLab issue #612
2022-05-17 11:52:36 +02:00

22 lines
427 B
Plaintext

import lexer_example
@with_lexer(foo_lexer)
grammar foo_grammar {
@main_rule main_rule <- Example("example")
}
@abstract class FooNode implements Node[FooNode] {
}
class Example : FooNode {
@export fun example_holders(): Array[ExampleHolder] =
[ExampleHolder(examples=[self])]
@export fun identity(a: Array[ExampleHolder]): Array[ExampleHolder] = a
}
struct ExampleHolder {
examples: Array[Example]
}