summaryrefslogtreecommitdiff
path: root/test/prism/snapshots/unparser/corpus/literal/rescue.txt
diff options
context:
space:
mode:
Diffstat (limited to 'test/prism/snapshots/unparser/corpus/literal/rescue.txt')
-rw-r--r--test/prism/snapshots/unparser/corpus/literal/rescue.txt103
1 files changed, 103 insertions, 0 deletions
diff --git a/test/prism/snapshots/unparser/corpus/literal/rescue.txt b/test/prism/snapshots/unparser/corpus/literal/rescue.txt
new file mode 100644
index 0000000000..d3c9d62166
--- /dev/null
+++ b/test/prism/snapshots/unparser/corpus/literal/rescue.txt
@@ -0,0 +1,103 @@
+@ ProgramNode (location: (1,0)-(3,27))
+├── locals: [:x]
+└── statements:
+ @ StatementsNode (location: (1,0)-(3,27))
+ └── body: (length: 3)
+ ├── @ RescueModifierNode (location: (1,0)-(1,14))
+ │ ├── expression:
+ │ │ @ CallNode (location: (1,0)-(1,3))
+ │ │ ├── flags: variable_call, ignore_visibility
+ │ │ ├── receiver: ∅
+ │ │ ├── call_operator_loc: ∅
+ │ │ ├── name: :foo
+ │ │ ├── message_loc: (1,0)-(1,3) = "foo"
+ │ │ ├── opening_loc: ∅
+ │ │ ├── arguments: ∅
+ │ │ ├── closing_loc: ∅
+ │ │ └── block: ∅
+ │ ├── keyword_loc: (1,4)-(1,10) = "rescue"
+ │ └── rescue_expression:
+ │ @ CallNode (location: (1,11)-(1,14))
+ │ ├── flags: variable_call, ignore_visibility
+ │ ├── receiver: ∅
+ │ ├── call_operator_loc: ∅
+ │ ├── name: :bar
+ │ ├── message_loc: (1,11)-(1,14) = "bar"
+ │ ├── opening_loc: ∅
+ │ ├── arguments: ∅
+ │ ├── closing_loc: ∅
+ │ └── block: ∅
+ ├── @ RescueModifierNode (location: (2,0)-(2,21))
+ │ ├── expression:
+ │ │ @ CallNode (location: (2,0)-(2,3))
+ │ │ ├── flags: variable_call, ignore_visibility
+ │ │ ├── receiver: ∅
+ │ │ ├── call_operator_loc: ∅
+ │ │ ├── name: :foo
+ │ │ ├── message_loc: (2,0)-(2,3) = "foo"
+ │ │ ├── opening_loc: ∅
+ │ │ ├── arguments: ∅
+ │ │ ├── closing_loc: ∅
+ │ │ └── block: ∅
+ │ ├── keyword_loc: (2,4)-(2,10) = "rescue"
+ │ └── rescue_expression:
+ │ @ ReturnNode (location: (2,11)-(2,21))
+ │ ├── flags: ∅
+ │ ├── keyword_loc: (2,11)-(2,17) = "return"
+ │ └── arguments:
+ │ @ ArgumentsNode (location: (2,18)-(2,21))
+ │ ├── flags: ∅
+ │ └── arguments: (length: 1)
+ │ └── @ CallNode (location: (2,18)-(2,21))
+ │ ├── flags: variable_call, ignore_visibility
+ │ ├── receiver: ∅
+ │ ├── call_operator_loc: ∅
+ │ ├── name: :bar
+ │ ├── message_loc: (2,18)-(2,21) = "bar"
+ │ ├── opening_loc: ∅
+ │ ├── arguments: ∅
+ │ ├── closing_loc: ∅
+ │ └── block: ∅
+ └── @ LocalVariableWriteNode (location: (3,0)-(3,27))
+ ├── name: :x
+ ├── depth: 0
+ ├── name_loc: (3,0)-(3,1) = "x"
+ ├── value:
+ │ @ ParenthesesNode (location: (3,4)-(3,27))
+ │ ├── body:
+ │ │ @ StatementsNode (location: (3,5)-(3,26))
+ │ │ └── body: (length: 1)
+ │ │ └── @ RescueModifierNode (location: (3,5)-(3,26))
+ │ │ ├── expression:
+ │ │ │ @ CallNode (location: (3,5)-(3,8))
+ │ │ │ ├── flags: variable_call, ignore_visibility
+ │ │ │ ├── receiver: ∅
+ │ │ │ ├── call_operator_loc: ∅
+ │ │ │ ├── name: :foo
+ │ │ │ ├── message_loc: (3,5)-(3,8) = "foo"
+ │ │ │ ├── opening_loc: ∅
+ │ │ │ ├── arguments: ∅
+ │ │ │ ├── closing_loc: ∅
+ │ │ │ └── block: ∅
+ │ │ ├── keyword_loc: (3,9)-(3,15) = "rescue"
+ │ │ └── rescue_expression:
+ │ │ @ ReturnNode (location: (3,16)-(3,26))
+ │ │ ├── flags: ∅
+ │ │ ├── keyword_loc: (3,16)-(3,22) = "return"
+ │ │ └── arguments:
+ │ │ @ ArgumentsNode (location: (3,23)-(3,26))
+ │ │ ├── flags: ∅
+ │ │ └── arguments: (length: 1)
+ │ │ └── @ CallNode (location: (3,23)-(3,26))
+ │ │ ├── flags: variable_call, ignore_visibility
+ │ │ ├── receiver: ∅
+ │ │ ├── call_operator_loc: ∅
+ │ │ ├── name: :bar
+ │ │ ├── message_loc: (3,23)-(3,26) = "bar"
+ │ │ ├── opening_loc: ∅
+ │ │ ├── arguments: ∅
+ │ │ ├── closing_loc: ∅
+ │ │ └── block: ∅
+ │ ├── opening_loc: (3,4)-(3,5) = "("
+ │ └── closing_loc: (3,26)-(3,27) = ")"
+ └── operator_loc: (3,2)-(3,3) = "="