Skip to content

Transform to ast with ruby 1.8 fallback#87

Closed
LTe wants to merge 2 commits intoopenSUSE:masterfrom
LTe:transform_to_ast
Closed

Transform to ast with ruby 1.8 fallback#87
LTe wants to merge 2 commits intoopenSUSE:masterfrom
LTe:transform_to_ast

Conversation

@LTe
Copy link
Copy Markdown
Member

@LTe LTe commented Aug 1, 2012

When Rubinius can't parse ruby file raise SyntaxError. But from time to time file is compiled only with ruby 1.8. Now scanny have fallback to 1.8 parser.

LTe added 2 commits August 1, 2012 13:41
When Rubinius can't parse ruby file transform_to_ast have fallback for
ruby 1.8 syntax
@dmajda
Copy link
Copy Markdown
Contributor

dmajda commented Aug 1, 2012

I don't like the approach of this pull request. I think a better solution would be to allow an explicit choice of Ruby version using a command-line option (default being 1.9).

@LTe
Copy link
Copy Markdown
Member Author

LTe commented Aug 2, 2012

I don't like the approach of this pull request. I think a better solution would be to allow an explicit choice of Ruby version using a command-line option (default being 1.9).

This is little hacky, I agree. Command line option sound good, I will implement this.

Generally it's better to have the code symmetric, so Rubinius::Melbourne19.new("(eval)", 1).parse_string(input) should probably have been used here.

Ok

@LTe LTe closed this Aug 2, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants