Skip to content

Commit 5b1dd31

Browse files
committed
Annotate local variable write/read nodes in YAML fixtures with a variable name when it's declared in outer scope
1 parent caf818c commit 5b1dd31

21 files changed

+86
-56
lines changed

spec/truffle/parsing/fixtures/for/multi_assignment/with_multiple_variables.yaml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -143,17 +143,17 @@ ast: |
143143
attributes:
144144
flags = 0
145145
frameDepth = 1
146-
frameSlot = 3
146+
frameSlot = 3 # a
147147
WriteDeclarationVariableNode
148148
attributes:
149149
flags = 0
150150
frameDepth = 1
151-
frameSlot = 4
151+
frameSlot = 4 # b
152152
WriteDeclarationVariableNode
153153
attributes:
154154
flags = 0
155155
frameDepth = 1
156-
frameSlot = 5
156+
frameSlot = 5 # c
157157
]
158158
rhsNode =
159159
ReadLocalVariableNode
@@ -172,7 +172,7 @@ ast: |
172172
attributes:
173173
flags = 1
174174
frameDepth = 1
175-
frameSlot = 6
175+
frameSlot = 6 # array
176176
children:
177177
valueNode =
178178
ArrayLiteralNode$UninitialisedArrayLiteralNode
@@ -185,19 +185,19 @@ ast: |
185185
attributes:
186186
flags = 0
187187
frameDepth = 1
188-
frameSlot = 3
188+
frameSlot = 3 # a
189189
type = FRAME_LOCAL
190190
ReadDeclarationVariableNode
191191
attributes:
192192
flags = 0
193193
frameDepth = 1
194-
frameSlot = 4
194+
frameSlot = 4 # b
195195
type = FRAME_LOCAL
196196
ReadDeclarationVariableNode
197197
attributes:
198198
flags = 0
199199
frameDepth = 1
200-
frameSlot = 5
200+
frameSlot = 5 # c
201201
type = FRAME_LOCAL
202202
]
203203
]

spec/truffle/parsing/fixtures/for/multi_assignment/with_nested_multi_assignment.yaml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ ast: |
143143
attributes:
144144
flags = 0
145145
frameDepth = 1
146-
frameSlot = 3
146+
frameSlot = 3 # a
147147
MultipleAssignmentNode
148148
attributes:
149149
flags = 0
@@ -153,12 +153,12 @@ ast: |
153153
attributes:
154154
flags = 0
155155
frameDepth = 1
156-
frameSlot = 4
156+
frameSlot = 4 # b
157157
WriteDeclarationVariableNode
158158
attributes:
159159
flags = 0
160160
frameDepth = 1
161-
frameSlot = 5
161+
frameSlot = 5 # c
162162
]
163163
splatCastNode =
164164
SplatCastNodeGen
@@ -185,7 +185,7 @@ ast: |
185185
attributes:
186186
flags = 1
187187
frameDepth = 1
188-
frameSlot = 6
188+
frameSlot = 6 # array
189189
children:
190190
valueNode =
191191
ArrayLiteralNode$UninitialisedArrayLiteralNode
@@ -198,19 +198,19 @@ ast: |
198198
attributes:
199199
flags = 0
200200
frameDepth = 1
201-
frameSlot = 3
201+
frameSlot = 3 # a
202202
type = FRAME_LOCAL
203203
ReadDeclarationVariableNode
204204
attributes:
205205
flags = 0
206206
frameDepth = 1
207-
frameSlot = 4
207+
frameSlot = 4 # b
208208
type = FRAME_LOCAL
209209
ReadDeclarationVariableNode
210210
attributes:
211211
flags = 0
212212
frameDepth = 1
213-
frameSlot = 5
213+
frameSlot = 5 # c
214214
type = FRAME_LOCAL
215215
]
216216
]

0 commit comments

Comments
 (0)