diff options
Diffstat (limited to 'test/prism/snapshots/seattlerb/TestRubyParserShared.txt')
-rw-r--r-- | test/prism/snapshots/seattlerb/TestRubyParserShared.txt | 361 |
1 files changed, 361 insertions, 0 deletions
diff --git a/test/prism/snapshots/seattlerb/TestRubyParserShared.txt b/test/prism/snapshots/seattlerb/TestRubyParserShared.txt new file mode 100644 index 0000000000..fabc92e477 --- /dev/null +++ b/test/prism/snapshots/seattlerb/TestRubyParserShared.txt @@ -0,0 +1,361 @@ +@ ProgramNode (location: (1,0)-(92,1)) +├── locals: [] +└── statements: + @ StatementsNode (location: (1,0)-(92,1)) + └── body: (length: 16) + ├── @ ArrayNode (location: (1,0)-(4,1)) + │ ├── flags: ∅ + │ ├── elements: (length: 0) + │ ├── opening_loc: (1,0)-(1,3) = "%I[" + │ └── closing_loc: (4,0)-(4,1) = "]" + ├── @ ArrayNode (location: (6,0)-(9,1)) + │ ├── flags: ∅ + │ ├── elements: (length: 2) + │ │ ├── @ SymbolNode (location: (7,0)-(7,5)) + │ │ │ ├── flags: forced_us_ascii_encoding + │ │ │ ├── opening_loc: ∅ + │ │ │ ├── value_loc: (7,0)-(7,5) = "line2" + │ │ │ ├── closing_loc: ∅ + │ │ │ └── unescaped: "line2" + │ │ └── @ SymbolNode (location: (8,0)-(8,5)) + │ │ ├── flags: forced_us_ascii_encoding + │ │ ├── opening_loc: ∅ + │ │ ├── value_loc: (8,0)-(8,5) = "line3" + │ │ ├── closing_loc: ∅ + │ │ └── unescaped: "line3" + │ ├── opening_loc: (6,0)-(6,3) = "%I[" + │ └── closing_loc: (9,0)-(9,1) = "]" + ├── @ ArrayNode (location: (11,0)-(14,1)) + │ ├── flags: ∅ + │ ├── elements: (length: 0) + │ ├── opening_loc: (11,0)-(11,3) = "%W[" + │ └── closing_loc: (14,0)-(14,1) = "]" + ├── @ ArrayNode (location: (16,0)-(19,1)) + │ ├── flags: ∅ + │ ├── elements: (length: 2) + │ │ ├── @ StringNode (location: (17,0)-(17,5)) + │ │ │ ├── flags: ∅ + │ │ │ ├── opening_loc: ∅ + │ │ │ ├── content_loc: (17,0)-(17,5) = "line2" + │ │ │ ├── closing_loc: ∅ + │ │ │ └── unescaped: "line2" + │ │ └── @ StringNode (location: (18,0)-(18,5)) + │ │ ├── flags: ∅ + │ │ ├── opening_loc: ∅ + │ │ ├── content_loc: (18,0)-(18,5) = "line3" + │ │ ├── closing_loc: ∅ + │ │ └── unescaped: "line3" + │ ├── opening_loc: (16,0)-(16,3) = "%W[" + │ └── closing_loc: (19,0)-(19,1) = "]" + ├── @ ArrayNode (location: (21,0)-(24,1)) + │ ├── flags: ∅ + │ ├── elements: (length: 0) + │ ├── opening_loc: (21,0)-(21,3) = "%i[" + │ └── closing_loc: (24,0)-(24,1) = "]" + ├── @ ArrayNode (location: (26,0)-(29,1)) + │ ├── flags: ∅ + │ ├── elements: (length: 2) + │ │ ├── @ SymbolNode (location: (27,0)-(27,5)) + │ │ │ ├── flags: forced_us_ascii_encoding + │ │ │ ├── opening_loc: ∅ + │ │ │ ├── value_loc: (27,0)-(27,5) = "line2" + │ │ │ ├── closing_loc: ∅ + │ │ │ └── unescaped: "line2" + │ │ └── @ SymbolNode (location: (28,0)-(28,5)) + │ │ ├── flags: forced_us_ascii_encoding + │ │ ├── opening_loc: ∅ + │ │ ├── value_loc: (28,0)-(28,5) = "line3" + │ │ ├── closing_loc: ∅ + │ │ └── unescaped: "line3" + │ ├── opening_loc: (26,0)-(26,3) = "%i[" + │ └── closing_loc: (29,0)-(29,1) = "]" + ├── @ RegularExpressionNode (location: (31,0)-(34,1)) + │ ├── flags: forced_us_ascii_encoding + │ ├── opening_loc: (31,0)-(31,3) = "%r[" + │ ├── content_loc: (31,3)-(34,0) = "\n\n\n" + │ ├── closing_loc: (34,0)-(34,1) = "]" + │ └── unescaped: "\n\n\n" + ├── @ ArrayNode (location: (36,0)-(39,1)) + │ ├── flags: ∅ + │ ├── elements: (length: 0) + │ ├── opening_loc: (36,0)-(36,3) = "%w[" + │ └── closing_loc: (39,0)-(39,1) = "]" + ├── @ ArrayNode (location: (41,0)-(44,1)) + │ ├── flags: ∅ + │ ├── elements: (length: 2) + │ │ ├── @ StringNode (location: (42,0)-(42,5)) + │ │ │ ├── flags: ∅ + │ │ │ ├── opening_loc: ∅ + │ │ │ ├── content_loc: (42,0)-(42,5) = "line2" + │ │ │ ├── closing_loc: ∅ + │ │ │ └── unescaped: "line2" + │ │ └── @ StringNode (location: (43,0)-(43,5)) + │ │ ├── flags: ∅ + │ │ ├── opening_loc: ∅ + │ │ ├── content_loc: (43,0)-(43,5) = "line3" + │ │ ├── closing_loc: ∅ + │ │ └── unescaped: "line3" + │ ├── opening_loc: (41,0)-(41,3) = "%w[" + │ └── closing_loc: (44,0)-(44,1) = "]" + ├── @ ArrayNode (location: (46,0)-(49,1)) + │ ├── flags: ∅ + │ ├── elements: (length: 2) + │ │ ├── @ SymbolNode (location: (47,0)-(47,6)) + │ │ │ ├── flags: forced_us_ascii_encoding + │ │ │ ├── opening_loc: (47,0)-(47,1) = ":" + │ │ │ ├── value_loc: (47,1)-(47,6) = "line2" + │ │ │ ├── closing_loc: ∅ + │ │ │ └── unescaped: "line2" + │ │ └── @ SymbolNode (location: (48,0)-(48,6)) + │ │ ├── flags: forced_us_ascii_encoding + │ │ ├── opening_loc: (48,0)-(48,1) = ":" + │ │ ├── value_loc: (48,1)-(48,6) = "line3" + │ │ ├── closing_loc: ∅ + │ │ └── unescaped: "line3" + │ ├── opening_loc: (46,0)-(46,1) = "[" + │ └── closing_loc: (49,0)-(49,1) = "]" + ├── @ ClassNode (location: (51,0)-(56,3)) + │ ├── locals: [] + │ ├── class_keyword_loc: (51,0)-(51,5) = "class" + │ ├── constant_path: + │ │ @ ConstantReadNode (location: (51,6)-(51,7)) + │ │ └── name: :X + │ ├── inheritance_operator_loc: ∅ + │ ├── superclass: ∅ + │ ├── body: + │ │ @ StatementsNode (location: (52,2)-(55,5)) + │ │ └── body: (length: 1) + │ │ └── @ DefNode (location: (52,2)-(55,5)) + │ │ ├── name: :y + │ │ ├── name_loc: (52,11)-(52,12) = "y" + │ │ ├── receiver: + │ │ │ @ SelfNode (location: (52,6)-(52,10)) + │ │ ├── parameters: + │ │ │ @ ParametersNode (location: (52,13)-(53,9)) + │ │ │ ├── requireds: (length: 2) + │ │ │ │ ├── @ RequiredParameterNode (location: (52,13)-(52,14)) + │ │ │ │ │ ├── flags: ∅ + │ │ │ │ │ └── name: :a + │ │ │ │ └── @ RequiredParameterNode (location: (53,8)-(53,9)) + │ │ │ │ ├── flags: ∅ + │ │ │ │ └── name: :b + │ │ │ ├── optionals: (length: 0) + │ │ │ ├── rest: ∅ + │ │ │ ├── posts: (length: 0) + │ │ │ ├── keywords: (length: 0) + │ │ │ ├── keyword_rest: ∅ + │ │ │ └── block: ∅ + │ │ ├── body: + │ │ │ @ StatementsNode (location: (54,4)-(54,9)) + │ │ │ └── body: (length: 1) + │ │ │ └── @ CallNode (location: (54,4)-(54,9)) + │ │ │ ├── flags: ∅ + │ │ │ ├── receiver: + │ │ │ │ @ LocalVariableReadNode (location: (54,4)-(54,5)) + │ │ │ │ ├── name: :a + │ │ │ │ └── depth: 0 + │ │ │ ├── call_operator_loc: ∅ + │ │ │ ├── name: :+ + │ │ │ ├── message_loc: (54,6)-(54,7) = "+" + │ │ │ ├── opening_loc: ∅ + │ │ │ ├── arguments: + │ │ │ │ @ ArgumentsNode (location: (54,8)-(54,9)) + │ │ │ │ ├── flags: ∅ + │ │ │ │ └── arguments: (length: 1) + │ │ │ │ └── @ LocalVariableReadNode (location: (54,8)-(54,9)) + │ │ │ │ ├── name: :b + │ │ │ │ └── depth: 0 + │ │ │ ├── closing_loc: ∅ + │ │ │ └── block: ∅ + │ │ ├── locals: [:a, :b] + │ │ ├── def_keyword_loc: (52,2)-(52,5) = "def" + │ │ ├── operator_loc: (52,10)-(52,11) = "." + │ │ ├── lparen_loc: (52,12)-(52,13) = "(" + │ │ ├── rparen_loc: (53,9)-(53,10) = ")" + │ │ ├── equal_loc: ∅ + │ │ └── end_keyword_loc: (55,2)-(55,5) = "end" + │ ├── end_keyword_loc: (56,0)-(56,3) = "end" + │ └── name: :X + ├── @ ClassNode (location: (59,0)-(63,3)) + │ ├── locals: [] + │ ├── class_keyword_loc: (59,0)-(59,5) = "class" + │ ├── constant_path: + │ │ @ ConstantReadNode (location: (59,6)-(59,7)) + │ │ └── name: :X + │ ├── inheritance_operator_loc: ∅ + │ ├── superclass: ∅ + │ ├── body: + │ │ @ StatementsNode (location: (60,2)-(62,5)) + │ │ └── body: (length: 1) + │ │ └── @ ClassNode (location: (60,2)-(62,5)) + │ │ ├── locals: [] + │ │ ├── class_keyword_loc: (60,2)-(60,7) = "class" + │ │ ├── constant_path: + │ │ │ @ ConstantReadNode (location: (60,8)-(60,9)) + │ │ │ └── name: :Y + │ │ ├── inheritance_operator_loc: ∅ + │ │ ├── superclass: ∅ + │ │ ├── body: + │ │ │ @ StatementsNode (location: (61,4)-(61,10)) + │ │ │ └── body: (length: 1) + │ │ │ └── @ ConstantWriteNode (location: (61,4)-(61,10)) + │ │ │ ├── name: :Z + │ │ │ ├── name_loc: (61,4)-(61,5) = "Z" + │ │ │ ├── value: + │ │ │ │ @ IntegerNode (location: (61,8)-(61,10)) + │ │ │ │ ├── flags: decimal + │ │ │ │ └── value: 42 + │ │ │ └── operator_loc: (61,6)-(61,7) = "=" + │ │ ├── end_keyword_loc: (62,2)-(62,5) = "end" + │ │ └── name: :Y + │ ├── end_keyword_loc: (63,0)-(63,3) = "end" + │ └── name: :X + ├── @ ClassNode (location: (66,0)-(71,3)) + │ ├── locals: [] + │ ├── class_keyword_loc: (66,0)-(66,5) = "class" + │ ├── constant_path: + │ │ @ ConstantReadNode (location: (66,6)-(66,7)) + │ │ └── name: :X + │ ├── inheritance_operator_loc: ∅ + │ ├── superclass: ∅ + │ ├── body: + │ │ @ StatementsNode (location: (67,2)-(70,5)) + │ │ └── body: (length: 1) + │ │ └── @ DefNode (location: (67,2)-(70,5)) + │ │ ├── name: :y + │ │ ├── name_loc: (67,6)-(67,7) = "y" + │ │ ├── receiver: ∅ + │ │ ├── parameters: + │ │ │ @ ParametersNode (location: (67,8)-(68,9)) + │ │ │ ├── requireds: (length: 2) + │ │ │ │ ├── @ RequiredParameterNode (location: (67,8)-(67,9)) + │ │ │ │ │ ├── flags: ∅ + │ │ │ │ │ └── name: :a + │ │ │ │ └── @ RequiredParameterNode (location: (68,8)-(68,9)) + │ │ │ │ ├── flags: ∅ + │ │ │ │ └── name: :b + │ │ │ ├── optionals: (length: 0) + │ │ │ ├── rest: ∅ + │ │ │ ├── posts: (length: 0) + │ │ │ ├── keywords: (length: 0) + │ │ │ ├── keyword_rest: ∅ + │ │ │ └── block: ∅ + │ │ ├── body: + │ │ │ @ StatementsNode (location: (69,4)-(69,9)) + │ │ │ └── body: (length: 1) + │ │ │ └── @ CallNode (location: (69,4)-(69,9)) + │ │ │ ├── flags: ∅ + │ │ │ ├── receiver: + │ │ │ │ @ LocalVariableReadNode (location: (69,4)-(69,5)) + │ │ │ │ ├── name: :a + │ │ │ │ └── depth: 0 + │ │ │ ├── call_operator_loc: ∅ + │ │ │ ├── name: :+ + │ │ │ ├── message_loc: (69,6)-(69,7) = "+" + │ │ │ ├── opening_loc: ∅ + │ │ │ ├── arguments: + │ │ │ │ @ ArgumentsNode (location: (69,8)-(69,9)) + │ │ │ │ ├── flags: ∅ + │ │ │ │ └── arguments: (length: 1) + │ │ │ │ └── @ LocalVariableReadNode (location: (69,8)-(69,9)) + │ │ │ │ ├── name: :b + │ │ │ │ └── depth: 0 + │ │ │ ├── closing_loc: ∅ + │ │ │ └── block: ∅ + │ │ ├── locals: [:a, :b] + │ │ ├── def_keyword_loc: (67,2)-(67,5) = "def" + │ │ ├── operator_loc: ∅ + │ │ ├── lparen_loc: (67,7)-(67,8) = "(" + │ │ ├── rparen_loc: (68,9)-(68,10) = ")" + │ │ ├── equal_loc: ∅ + │ │ └── end_keyword_loc: (70,2)-(70,5) = "end" + │ ├── end_keyword_loc: (71,0)-(71,3) = "end" + │ └── name: :X + ├── @ ModuleNode (location: (74,0)-(79,3)) + │ ├── locals: [] + │ ├── module_keyword_loc: (74,0)-(74,6) = "module" + │ ├── constant_path: + │ │ @ ConstantReadNode (location: (74,7)-(74,8)) + │ │ └── name: :X + │ ├── body: + │ │ @ StatementsNode (location: (75,2)-(78,3)) + │ │ └── body: (length: 1) + │ │ └── @ ConstantWriteNode (location: (75,2)-(78,3)) + │ │ ├── name: :X + │ │ ├── name_loc: (75,2)-(75,3) = "X" + │ │ ├── value: + │ │ │ @ ArrayNode (location: (75,6)-(78,3)) + │ │ │ ├── flags: ∅ + │ │ │ ├── elements: (length: 2) + │ │ │ │ ├── @ SymbolNode (location: (76,4)-(76,10)) + │ │ │ │ │ ├── flags: forced_us_ascii_encoding + │ │ │ │ │ ├── opening_loc: (76,4)-(76,5) = ":" + │ │ │ │ │ ├── value_loc: (76,5)-(76,10) = "line3" + │ │ │ │ │ ├── closing_loc: ∅ + │ │ │ │ │ └── unescaped: "line3" + │ │ │ │ └── @ SymbolNode (location: (77,4)-(77,10)) + │ │ │ │ ├── flags: forced_us_ascii_encoding + │ │ │ │ ├── opening_loc: (77,4)-(77,5) = ":" + │ │ │ │ ├── value_loc: (77,5)-(77,10) = "line4" + │ │ │ │ ├── closing_loc: ∅ + │ │ │ │ └── unescaped: "line4" + │ │ │ ├── opening_loc: (75,6)-(75,7) = "[" + │ │ │ └── closing_loc: (78,2)-(78,3) = "]" + │ │ └── operator_loc: (75,4)-(75,5) = "=" + │ ├── end_keyword_loc: (79,0)-(79,3) = "end" + │ └── name: :X + ├── @ ModuleNode (location: (82,0)-(86,3)) + │ ├── locals: [] + │ ├── module_keyword_loc: (82,0)-(82,6) = "module" + │ ├── constant_path: + │ │ @ ConstantReadNode (location: (82,7)-(82,8)) + │ │ └── name: :X + │ ├── body: + │ │ @ StatementsNode (location: (83,2)-(85,5)) + │ │ └── body: (length: 1) + │ │ └── @ ModuleNode (location: (83,2)-(85,5)) + │ │ ├── locals: [] + │ │ ├── module_keyword_loc: (83,2)-(83,8) = "module" + │ │ ├── constant_path: + │ │ │ @ ConstantReadNode (location: (83,9)-(83,10)) + │ │ │ └── name: :Y + │ │ ├── body: + │ │ │ @ StatementsNode (location: (84,4)-(84,10)) + │ │ │ └── body: (length: 1) + │ │ │ └── @ ConstantWriteNode (location: (84,4)-(84,10)) + │ │ │ ├── name: :Z + │ │ │ ├── name_loc: (84,4)-(84,5) = "Z" + │ │ │ ├── value: + │ │ │ │ @ IntegerNode (location: (84,8)-(84,10)) + │ │ │ │ ├── flags: decimal + │ │ │ │ └── value: 42 + │ │ │ └── operator_loc: (84,6)-(84,7) = "=" + │ │ ├── end_keyword_loc: (85,2)-(85,5) = "end" + │ │ └── name: :Y + │ ├── end_keyword_loc: (86,0)-(86,3) = "end" + │ └── name: :X + └── @ CallNode (location: (89,0)-(92,1)) + ├── flags: ignore_visibility + ├── receiver: ∅ + ├── call_operator_loc: ∅ + ├── name: :x + ├── message_loc: (89,0)-(89,1) = "x" + ├── opening_loc: (89,1)-(89,2) = "(" + ├── arguments: + │ @ ArgumentsNode (location: (90,0)-(91,6)) + │ ├── flags: ∅ + │ └── arguments: (length: 2) + │ ├── @ SymbolNode (location: (90,0)-(90,6)) + │ │ ├── flags: forced_us_ascii_encoding + │ │ ├── opening_loc: (90,0)-(90,1) = ":" + │ │ ├── value_loc: (90,1)-(90,6) = "line2" + │ │ ├── closing_loc: ∅ + │ │ └── unescaped: "line2" + │ └── @ SymbolNode (location: (91,0)-(91,6)) + │ ├── flags: forced_us_ascii_encoding + │ ├── opening_loc: (91,0)-(91,1) = ":" + │ ├── value_loc: (91,1)-(91,6) = "line3" + │ ├── closing_loc: ∅ + │ └── unescaped: "line3" + ├── closing_loc: (92,0)-(92,1) = ")" + └── block: ∅ |