mbj/unparser

Relax parser requirements to work with 2.5.0.0+

Closed this issue · 3 comments

parser 2.5.0.0 was released: https://github.com/whitequark/parser/blob/master/CHANGELOG.md

Is there any reason we can't relax the requirements to allow for 2.5.0 as well?

mbj commented

Is there any reason we can't relax the requirements to allow for 2.5.0 as well?

It was not yet tested against the unparser test suite ;) Quite a simple reason.

What is necessary to verify the unparser is 2.5 compatible?

I'm trying to verify 2.5 compatibility by running the tests, but for rubies 2.3.4-2.5.0 the spec suite fails on the rubyspec repo. All rubies fail in the same way, with the same errors in

Error: (/home/wever/dev/unparser/tmp/rubyspec/command_line/fixtures/bad_syntax.rb)
Error: (/home/wever/dev/unparser/tmp/rubyspec/core/string/shared/to_sym.rb)
Error: (/home/wever/dev/unparser/tmp/rubyspec/language/fixtures/binary_symbol.rb)
Error: (/home/wever/dev/unparser/tmp/rubyspec/language/for_spec.rb)

This is using the latest 'parser' versions of 2.3, 2.4 and 2.5 (I included local versions of devtools and mutant with constraints removed to enable upgrading to parser 2.5).

So I currently don't have a passing baseline to start from, which makes it difficult to understand whether anything has changed.

mbj commented

So I currently don't have a passing baseline to start from, which makes it difficult to understand whether anything has changed.

This is because rubyspec moved and added new parser/unparser incompatible syntax in other places.

Simply whitelist these as they fall into the limitations, and I'm fine.