bin/benchmark in parser-1.0.1 vs bin/benchmark in parser-1.1.0
- old
+ new
@@ -13,24 +13,24 @@
Benchmark.bm(10) do |x|
x.report "ruby_parser" do
what.each do |file, src|
begin
Ruby18Parser.new.parse(src)
- rescue Exception => e
+ rescue => e
puts file
puts "RP: #{e.class}: #{e.message}"
rp_failures += 1
end
end
end
x.report "parser" do
what.each do |file, src|
begin
- Parser::Ruby18.parse(src, file)
+ Parser::Ruby20.parse(src, file)
rescue Parser::SyntaxError
p_failures += 1
- rescue Exception => e
+ rescue => e
puts file
puts "P: #{e.class}: #{e.message}"
puts e.backtrace
p_failures += 1
end