File tree 2 files changed +23
-31
lines changed
2 files changed +23
-31
lines changed Original file line number Diff line number Diff line change @@ -3036,10 +3036,7 @@ def on_qsymbols_new
3036
3036
3037
3037
ArrayLiteral . new (
3038
3038
lbracket : beginning ,
3039
- contents : Args . new (
3040
- parts : [ ] ,
3041
- location : beginning . location
3042
- ) ,
3039
+ contents : Args . new ( parts : [ ] , location : beginning . location ) ,
3043
3040
location : beginning . location
3044
3041
)
3045
3042
end
@@ -3083,10 +3080,7 @@ def on_qwords_new
3083
3080
3084
3081
ArrayLiteral . new (
3085
3082
lbracket : beginning ,
3086
- contents : Args . new (
3087
- parts : [ ] ,
3088
- location : beginning . location
3089
- ) ,
3083
+ contents : Args . new ( parts : [ ] , location : beginning . location ) ,
3090
3084
location : beginning . location
3091
3085
)
3092
3086
end
@@ -3653,10 +3647,7 @@ def on_symbols_new
3653
3647
3654
3648
ArrayLiteral . new (
3655
3649
lbracket : beginning ,
3656
- contents : Args . new (
3657
- parts : [ ] ,
3658
- location : beginning . location
3659
- ) ,
3650
+ contents : Args . new ( parts : [ ] , location : beginning . location ) ,
3660
3651
location : beginning . location
3661
3652
)
3662
3653
end
@@ -4110,10 +4101,7 @@ def on_words_new
4110
4101
4111
4102
ArrayLiteral . new (
4112
4103
lbracket : beginning ,
4113
- contents : Args . new (
4114
- parts : [ ] ,
4115
- location : beginning . location
4116
- ) ,
4104
+ contents : Args . new ( parts : [ ] , location : beginning . location ) ,
4117
4105
location : beginning . location
4118
4106
)
4119
4107
end
Original file line number Diff line number Diff line change @@ -257,23 +257,27 @@ def visit_array(node)
257
257
if node . contents . nil?
258
258
[ ]
259
259
elsif node . lbracket . is_a? ( QSymbolsBeg )
260
- visit_all ( node . contents . parts . map do |part |
261
- SymbolLiteral . new ( value : part , location : part . location )
262
- end )
263
- elsif node . lbracket . is_a? ( SymbolsBeg )
264
- visit_all ( node . contents . parts . map do |element |
265
- part = element . parts . first
266
-
267
- if element . parts . length == 1 && part . is_a? ( TStringContent )
260
+ visit_all (
261
+ node . contents . parts . map do |part |
268
262
SymbolLiteral . new ( value : part , location : part . location )
269
- else
270
- DynaSymbol . new (
271
- parts : element . parts ,
272
- quote : nil ,
273
- location : element . location
274
- )
275
263
end
276
- end )
264
+ )
265
+ elsif node . lbracket . is_a? ( SymbolsBeg )
266
+ visit_all (
267
+ node . contents . parts . map do |element |
268
+ part = element . parts . first
269
+
270
+ if element . parts . length == 1 && part . is_a? ( TStringContent )
271
+ SymbolLiteral . new ( value : part , location : part . location )
272
+ else
273
+ DynaSymbol . new (
274
+ parts : element . parts ,
275
+ quote : nil ,
276
+ location : element . location
277
+ )
278
+ end
279
+ end
280
+ )
277
281
else
278
282
visit_all ( node . contents . parts )
279
283
end ,
You can’t perform that action at this time.
0 commit comments