ruby/test/prism/fixtures/encoding_binary.txt
Earlopain 723f31cf6b [ruby/prism] Fix binary encoding for the parser translator
Skipping detecting the encoding is almost always right, just for binary it should actually happen.

A symbol containing escapes that are invalid
in utf-8 would fail to parse since symbols must be valid in the script encoding.
Additionally, the parser gem would raise an exception somewhere during string handling

https://github.com/ruby/prism/commit/fa0154d9e4
2025-01-12 00:49:54 +00:00

10 lines
59 B
Plaintext

# encoding: binary
"\xcd"
:"\xcd"
/#{"\xcd"}/
%W[\xC0]