Open jamesrweb opened 7 months ago
I believe this is a dup of #447
I believe this is a dup of #447
Actually no, I believe this is similar but different in that, it fails on THIS file specifically but not on 2 others with similar constructs in place. Ruby runs all 3 perfectly fine.
If you want to mark it as a duplicate, you can, but it is still unique in my case to this code sample specifically.
What do you mean by "with similar constructs"? My point in calling this a duplicate is that all the individual expression types represented by this file are marked as bugs in other places: #447 for and
expressions and #399/#325 for pattern matching. If there are additional constructs in those other files you're referencing, then this may be distinct, but I'd need some additional information there.
What do you mean by "with similar constructs"? My point in calling this a duplicate is that all the individual expression types represented by this file are marked as bugs in other places: #447 for
and
expressions and #399/#325 for pattern matching. If there are additional constructs in those other files you're referencing, then this may be distinct, but I'd need some additional information there.
I mean the way to load and parse the files and output is roughly similar in those other files.
As I said, up to you, I appreciate the tool either way, just strange how it failed for this one. ☺️
Side question, are you considering switching to prism from ripper for ruby parsing?
Switching to prism would be great (largely because right now we have to have a whole Ruby checkout just to build Ripper, and just having prism on its own would make getting development way more lightweight), but it's also pretty far down on the priority list at the moment compared to getting things feature-complete for Ruby 3, fixing bugs, etc.
@reese what's the current plan for this? Is there a roadmap for prism or anything else we could use to resolve the issue?
Ruby executes the code perfectly fine and outputs the correct values but rubyfmt cannot format the document.
Input file
Rubyfmt's output
This breaks because
Rubyfmt failed to correctly deserialize a tree from ripper. (What is ripper even?)