Closed
Description
Hash value omission was introduced with ruby 3.1 - rubyreferences.github.io/rubychanges/3.1.html#values-in-hash-literals-and-keyword-arguments-can-be-omitted
And apparently it breaks flog:
ERROR: parsing ruby file example.rb
Racc::ParseError: example.rb:5 :: parse error on value "," (tCOMMA) at:
/usr/local/lib/ruby/2.6.0/racc/parser.rb:528:in `on_error'
/usr/local/bundle/gems/ruby_parser-3.13.1/lib/ruby_parser_extras.rb:1179:in `on_error'
/usr/local/lib/ruby/2.6.0/racc/parser.rb:259:in `_racc_do_parse_c'
/usr/local/lib/ruby/2.6.0/racc/parser.rb:259:in `do_parse'
/usr/local/bundle/gems/ruby_parser-3.13.1/lib/ruby_parser_extras.rb:1086:in `block in process'
example.rb
content:
# frozen_string_literal: true
class Example
def perform(id)
Model.find_by!(id:, something: :else)
end
end
This is also happens to the duplication engine (codeclimate/codeclimate-duplication#375)
Thanks
Metadata
Metadata
Assignees
Labels
No labels