Skip to content

SyntaxError: unexpected ... when the parent method is not forwarding #102

@ksss

Description

@ksss

Problem

SyntaxError: (eval at /Users/ksss/src/github.com/ksss/orthoses/lib/orthoses/call_tracer/capturable.rb:53):1: syntax error found (SyntaxError)
> 1 | __extract_rest_parameters__(...)
    |                             ^~~ unexpected ... when the parent method is not forwarding

Conditions

Ruby v3.4.1

Cause

This is a bug in Prism.
https://bugs.ruby-lang.org/issues/21031

Workaround

Use parse.y

  • ruby --parser=parse.y orthoses.rb
  • RUBYOPT='--parser=parse.y' bundle exec rake

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions