Skip to content

Commit

Permalink
Merge pull request #2721 from koic/use_parser_ruby34_for_bin_prism_pa…
Browse files Browse the repository at this point in the history
…rser

Use `Parser::Ruby34` for `bin/prism parser` command
  • Loading branch information
kddnewton committed Apr 19, 2024
2 parents 82fd925 + 3b6ae32 commit 3a07cff
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions bin/prism
Original file line number Diff line number Diff line change
Expand Up @@ -274,14 +274,14 @@ module Prism

# bin/prism parser [source]
def parser(argv)
require "parser/ruby33"
require "parser/ruby34"
source, filepath = read_source(argv)

buffer = Parser::Source::Buffer.new(filepath, 1)
buffer.source = source

puts "Parser:"
parser_parse(Parser::Ruby33.new, buffer)
parser_parse(Parser::Ruby34.new, buffer)

puts "Prism:"
parser_parse(Prism::Translation::Parser34.new, buffer)
Expand Down

0 comments on commit 3a07cff

Please sign in to comment.