Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: whitequark/parser
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v3.2.2.3
Choose a base ref
...
head repository: whitequark/parser
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v3.2.2.4
Choose a head ref
  • 7 commits
  • 7 files changed
  • 4 contributors

Commits on Jun 8, 2023

  1. Update changelog.

    iliabylich committed Jun 8, 2023
    Configuration menu
    Copy the full SHA
    58cd40d View commit details
    Browse the repository at this point in the history

Commits on Jun 15, 2023

  1. * bump Racc to 1.7.1 (#930)

    koic authored Jun 15, 2023
    Configuration menu
    Copy the full SHA
    e3813de View commit details
    Browse the repository at this point in the history

Commits on Sep 14, 2023

  1. Configuration menu
    Copy the full SHA
    cb0fc45 View commit details
    Browse the repository at this point in the history

Commits on Sep 17, 2023

  1. Configuration menu
    Copy the full SHA
    a9c45c5 View commit details
    Browse the repository at this point in the history

Commits on Oct 4, 2023

  1. - Fix an error for flip-flop with beginless or endless ranges (#946)

    This PR resolves rubocop/rubocop#12198.
    
    ```console
    $ ruby-parse -e 'if foo..; end'
    Failed on: (fragment:0)
    /Users/koic/.rbenv/versions/3.3.0-dev/lib/ruby/gems/3.3.0+0/gems/parser-3.2.2.3/lib/parser/builders/default.rb:1676:
    in `check_condition': undefined method `type' for nil (NoMethodError)
    
          case cond.type
                   ^^^^^
            from /Users/koic/.rbenv/versions/3.3.0-dev/lib/ruby/gems/3.3.0+0/gems/parser-3.2.2.3/lib/parser/builders/default.rb:1707:
            in `check_condition'
            from /Users/koic/.rbenv/versions/3.3.0-dev/lib/ruby/gems/3.3.0+0/gems/parser-3.2.2.3/lib/parser/builders/default.rb:1275:
            in `condition'
    ```
    
    I'm not sure if there's any significance to using the flip-flop syntax with `nil`,
    but by using beginless or endless ranges and explicitly specifying `nil`,
    the following current behaviors are made compatible:
    
    ## `iflipflop` with explicitly `nil`
    
    ```console
    $ ruby-parse -e 'if foo..nil ; end'
    (if
      (iflipflop
        (send nil :foo)
        (nil)) nil nil)
    ```
    
    ```console
    $ ruby-parse -e 'if nil..bar ; end'
    (if
      (iflipflop
        (nil)
        (send nil :bar)) nil nil)
    ```
    
    ## `eflipflop` with explicitly `nil`
    
    ```console
    $ ruby-parse -e 'if foo...nil ; end'
    (if
      (eflipflop
        (send nil :foo)
        (nil)) nil nil)
    ```
    
    ```console
    $ ruby-parse -e 'if nil...bar ; end'
    (if
      (eflipflop
        (nil)
        (send nil :bar)) nil nil)
    ```
    
    The difference in the flip-flop with beginless or endless ranges is
    that `s(:nil)` is replaced by `nil` in the flip-flop ASTs.
    
    This is reflected in the tests.
    koic authored Oct 4, 2023
    Configuration menu
    Copy the full SHA
    555ecec View commit details
    Browse the repository at this point in the history
  2. Bump version.

    iliabylich committed Oct 4, 2023
    Configuration menu
    Copy the full SHA
    0396c37 View commit details
    Browse the repository at this point in the history
  3. Update changelog.

    iliabylich committed Oct 4, 2023
    Configuration menu
    Copy the full SHA
    0bf410f View commit details
    Browse the repository at this point in the history
Loading