Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support Prism as a Ruby parser #304

Merged
merged 1 commit into from
Mar 4, 2024
Merged

Support Prism as a Ruby parser #304

merged 1 commit into from
Mar 4, 2024

Commits on Mar 4, 2024

  1. Support Prism as a Ruby parser

    Follow up rubocop/rubocop-ast#277
    
    There are no changes to the implementation, but the required dependency version of
    RuboCop AST will be updated. It would be more rational than adding new dependency on
    `gem 'rubocop-ast', '>= 1.31.1'` in the Gemfile just to bump up the minor version.
    
    RuboCop Minitest now ensures that `RuboCop::AST::ProcessedSource` used in tests is aware of
    `parser_engine` parameter.
    
    Tests for RuboCop AST with Prism as the backend can be run as follows:
    
    ```console
    bundle exec rake prism_test
    ```
    
    The above is the shortcut alias for:
    
    ```console
    PARSER_ENGINE=parser_prism bundle exec rake test
    ```
    
    RuboCop works on Ruby versions 2.7+, but since Prism only targets parsing for Ruby 3.3+,
    `internal_investigation` Rake task will not be executed. This task is only run with the Parser gem,
    which can parse Ruby versions 2.0+.
    koic committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    43b6ddb View commit details
    Browse the repository at this point in the history