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

Integrate YARP (aka Prism) #1213

Merged
merged 52 commits into from
Sep 22, 2023
Merged

Integrate YARP (aka Prism) #1213

merged 52 commits into from
Sep 22, 2023

Commits on Sep 11, 2023

  1. Get YARP building and parsing some basic calls

    This works:
    
        $ rake
    
        $ bin/natalie --ast -e "p 1+2"
        s(:block, s(:block, s(:call, nil, :p, s(:call, s(:lit, 1), :+, s(:lit, 2)))))
    
        $ bin/natalie -e "p 1+2"
        3
    seven1m committed Sep 11, 2023
    Configuration menu
    Copy the full SHA
    3d38499 View commit details
    Browse the repository at this point in the history
  2. Get examples/fib.rb parsing

    seven1m committed Sep 11, 2023
    Configuration menu
    Copy the full SHA
    8574221 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    0e94c34 View commit details
    Browse the repository at this point in the history
  4. Get the spec runner parsing

    I was trying to get test/natalie/method_test.rb parsing (and passing),
    but I found a few unexpected results from YARP. I think these are bugs,
    which I filed here:
    
    ruby/prism#1435
    ruby/prism#1436
    seven1m committed Sep 11, 2023
    Configuration menu
    Copy the full SHA
    26dd097 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    de0278c View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    7ddfbc9 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    2a5ac56 View commit details
    Browse the repository at this point in the history
  8. Add some nokogiri dependencies temporarily

    I'd love to find a way to avoid these dependencies. These are just for
    generating some sources for YARP, and are not used after that. I bet we
    can pre-generate YARP sources and commit to our repo...
    seven1m committed Sep 11, 2023
    Configuration menu
    Copy the full SHA
    671c9e4 View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    5a24cf5 View commit details
    Browse the repository at this point in the history
  10. Configuration menu
    Copy the full SHA
    c77c0ca View commit details
    Browse the repository at this point in the history

Commits on Sep 12, 2023

  1. Update YARP

    seven1m committed Sep 12, 2023
    Configuration menu
    Copy the full SHA
    a1c634a View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    30156a9 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    7c0aa77 View commit details
    Browse the repository at this point in the history
  4. Revert "Add some nokogiri dependencies temporarily"

    This reverts commit 671c9e4.
    seven1m committed Sep 12, 2023
    Configuration menu
    Copy the full SHA
    39a5c2e View commit details
    Browse the repository at this point in the history
  5. Store YARP generated sources in our repo

    This might allow us to skip installing some gems with bundler during the
    build process... I need to make sure this works across platforms.
    seven1m committed Sep 12, 2023
    Configuration menu
    Copy the full SHA
    3c750b8 View commit details
    Browse the repository at this point in the history
  6. Fix syntax to work with Ruby 3.0

    Hash literal value omission wasn't added until 3.1 :-)
    seven1m committed Sep 12, 2023
    Configuration menu
    Copy the full SHA
    b8dc641 View commit details
    Browse the repository at this point in the history

Commits on Sep 13, 2023

  1. Configuration menu
    Copy the full SHA
    82453a2 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    2dc94a1 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    e317ffd View commit details
    Browse the repository at this point in the history

Commits on Sep 14, 2023

  1. Configuration menu
    Copy the full SHA
    465540b View commit details
    Browse the repository at this point in the history
  2. Fix parsing of for and redo

    seven1m committed Sep 14, 2023
    Configuration menu
    Copy the full SHA
    924d778 View commit details
    Browse the repository at this point in the history
  3. Remove kludge for issue #1201

    seven1m committed Sep 14, 2023
    Configuration menu
    Copy the full SHA
    10b3379 View commit details
    Browse the repository at this point in the history
  4. Parse rational nodes

    seven1m committed Sep 14, 2023
    Configuration menu
    Copy the full SHA
    0527d4b View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    1c898a4 View commit details
    Browse the repository at this point in the history
  6. Parse interpolated symbols

    seven1m committed Sep 14, 2023
    Configuration menu
    Copy the full SHA
    95c94af View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    ef371e6 View commit details
    Browse the repository at this point in the history
  8. Don't rebuild YARP with rake clean (use clobber)

    `rake clean` cleans up our own sources, but not external libraries like
    YARP and Onigmo. If we need to rebuild external libraries, we can use
    `rake clobber build`.
    seven1m committed Sep 14, 2023
    Configuration menu
    Copy the full SHA
    2b82a84 View commit details
    Browse the repository at this point in the history
  9. Parse __LINE__

    seven1m committed Sep 14, 2023
    Configuration menu
    Copy the full SHA
    11b26d9 View commit details
    Browse the repository at this point in the history
  10. Configuration menu
    Copy the full SHA
    0bf27af View commit details
    Browse the repository at this point in the history
  11. Configuration menu
    Copy the full SHA
    0bff6b2 View commit details
    Browse the repository at this point in the history
  12. Parse undef

    seven1m committed Sep 14, 2023
    Configuration menu
    Copy the full SHA
    fab8d86 View commit details
    Browse the repository at this point in the history
  13. Match interpolated string node parsing with NatalieParser

    This returns a simpler node in a very specific case of "#{'str'}" which
    gets one spec passing that relied on that.
    seven1m committed Sep 14, 2023
    Configuration menu
    Copy the full SHA
    6de002d View commit details
    Browse the repository at this point in the history

Commits on Sep 15, 2023

  1. Fix yarp building on macos

    seven1m committed Sep 15, 2023
    Configuration menu
    Copy the full SHA
    5278d83 View commit details
    Browse the repository at this point in the history
  2. Fix bug with interpolated node extraction

    We have to keep the sexp_type for symbol, regex, etc.
    seven1m committed Sep 15, 2023
    Configuration menu
    Copy the full SHA
    792ddb4 View commit details
    Browse the repository at this point in the history
  3. Fix parsing of $' to match NatalieParser

    For now... once the test suite is passing, it would be good to come back
    and remove this whole compatibility layer and have pass1.rb just consume
    the YARP nodes directly. Baby steps. :-)
    seven1m committed Sep 15, 2023
    Configuration menu
    Copy the full SHA
    fc61795 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    ffb5f70 View commit details
    Browse the repository at this point in the history
  5. Update YARP

    seven1m committed Sep 15, 2023
    Configuration menu
    Copy the full SHA
    b250f8e View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    4910d6b View commit details
    Browse the repository at this point in the history
  7. Fix parsing of module names

    seven1m committed Sep 15, 2023
    Configuration menu
    Copy the full SHA
    6bbdf23 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    bcf85e9 View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    f66a54d View commit details
    Browse the repository at this point in the history
  10. Configuration menu
    Copy the full SHA
    4c40aca View commit details
    Browse the repository at this point in the history
  11. Fix $` parsing

    seven1m committed Sep 15, 2023
    Configuration menu
    Copy the full SHA
    391fa28 View commit details
    Browse the repository at this point in the history
  12. Fix (kinda) parsing of regexp match write node

    We don't handle the variable setting yet, but we didn't with
    NatalieParser either.
    seven1m committed Sep 15, 2023
    Configuration menu
    Copy the full SHA
    90dd862 View commit details
    Browse the repository at this point in the history
  13. Fix parsing of retry

    seven1m committed Sep 15, 2023
    Configuration menu
    Copy the full SHA
    0653488 View commit details
    Browse the repository at this point in the history

Commits on Sep 19, 2023

  1. Update YARP

    seven1m committed Sep 19, 2023
    Configuration menu
    Copy the full SHA
    5fe457c View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    26f2e6e View commit details
    Browse the repository at this point in the history
  3. Raise a slightly better syntax error

    I need to learn how to say something like "unexpected X, expected Y"...
    seven1m committed Sep 19, 2023
    Configuration menu
    Copy the full SHA
    fe5e469 View commit details
    Browse the repository at this point in the history

Commits on Sep 20, 2023

  1. Configuration menu
    Copy the full SHA
    11159b5 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    cd3714c View commit details
    Browse the repository at this point in the history

Commits on Sep 21, 2023

  1. Remove NatalieParser

    seven1m committed Sep 21, 2023
    Configuration menu
    Copy the full SHA
    92bfeb3 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    4e9ccf8 View commit details
    Browse the repository at this point in the history