File tree Expand file tree Collapse file tree 2 files changed +2
-3
lines changed
lib/prism/translation/parser Expand file tree Collapse file tree 2 files changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -339,7 +339,7 @@ def to_a
339
339
location = Range . new ( source_buffer , offset_cache [ token . location . start_offset ] , offset_cache [ token . location . start_offset + 1 ] )
340
340
end
341
341
when :tSYMBEG
342
- if ( next_token = lexed [ index ] [ 0 ] ) && next_token . type != :STRING_CONTENT && next_token . type != :EMBEXPR_BEGIN && next_token . type != :EMBVAR
342
+ if ( next_token = lexed [ index ] [ 0 ] ) && next_token . type != :STRING_CONTENT && next_token . type != :EMBEXPR_BEGIN && next_token . type != :EMBVAR && next_token . type != :STRING_END
343
343
next_location = token . location . join ( next_token . location )
344
344
type = :tSYMBOL
345
345
value = next_token . value
Original file line number Diff line number Diff line change @@ -144,7 +144,6 @@ class ParserTest < TestCase
144
144
"seattlerb/str_evstr_escape.txt" ,
145
145
"seattlerb/str_newline_hash_line_number.txt" ,
146
146
"seattlerb/str_single_newline.txt" ,
147
- "seattlerb/symbol_empty.txt" ,
148
147
"seattlerb/symbols_empty_space.txt" ,
149
148
"seattlerb/TestRubyParserShared.txt" ,
150
149
"unparser/corpus/literal/assignment.txt" ,
@@ -247,7 +246,7 @@ def assert_equal_tokens(expected_tokens, actual_tokens)
247
246
248
247
while expected_index < expected_tokens . length
249
248
expected_token = expected_tokens [ expected_index ]
250
- actual_token = actual_tokens [ actual_index ]
249
+ actual_token = actual_tokens . fetch ( actual_index , [ ] )
251
250
252
251
expected_index += 1
253
252
actual_index += 1
You can’t perform that action at this time.
0 commit comments