We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
headius
Learn more about funding links in repositories.
Report abuse
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Currently, the ouput of Ripper.lex is incorrect for imaginary and rational suffix numbers.
Ripper.lex
$ mri-local -rripper -rpp -e 'pp Ripper.lex "3i"' [[[1, 0], :on_imaginary, "3i"]] $ mri-local -rripper -rpp -e 'pp Ripper.lex "1.6ri"' [[[1, 0], :on_imaginary, "1.6ri"]] $ mri-local -rripper -rpp -e 'pp Ripper.lex "1.6i"' [[[1, 0], :on_imaginary, "1.6i"]] $ mri-local -rripper -rpp -e 'pp Ripper.lex "1.6r"' [[[1, 0], :on_rational, "1.6r"]] $ bin/jruby -rripper -rpp -e 'pp Ripper.lex "3i"' [[[1, 0], :on_int, "3"], [[1, 1], :on_ident, "i"]] $ bin/jruby -rripper -rpp -e 'pp Ripper.lex "1.6ri"' [[[1, 0], :on_float, "1.6"], [[1, 3], :on_ident, "ri"]] $ bin/jruby -rripper -rpp -e 'pp Ripper.lex "1.6i"' [[[1, 0], :on_float, "1.6"], [[1, 3], :on_ident, "i"]] $ bin/jruby -rripper -rpp -e 'pp Ripper.lex "1.6r"' [[[1, 0], :on_float, "1.6"], [[1, 3], :on_ident, "r"]]
But I recently fixed the RubyLexer for imaginary floats in 3e995ac.
The text was updated successfully, but these errors were encountered:
Works as expected on 9.1.9.0
require 'ripper' Ripper.lex "3i" # => [[[1, 0], :on_imaginary, "3i"]] Ripper.lex "1.6ri" # => [[[1, 0], :on_imaginary, "1.6ri"]] Ripper.lex "1.6i" # => [[[1, 0], :on_imaginary, "1.6i"]] Ripper.lex "1.6r" # => [[[1, 0], :on_rational, "1.6r"]]
Sorry, something went wrong.
enebo
No branches or pull requests
Currently, the ouput of
Ripper.lex
is incorrect for imaginary and rational suffix numbers.But I recently fixed the RubyLexer for imaginary floats in 3e995ac.
The text was updated successfully, but these errors were encountered: