Skip to content

Pattern matching with an empty hash should result in no match #7854

@palkan

Description

@palkan

Environment Information

Provide at least:

  • JRuby version (jruby -v): jruby 9.4.3.0 (3.1.4) 2023-06-07 3086960 OpenJDK 64-Bit Server VM 25.372-b07 on 1.8.0_372-b07 +jit [aarch64-linux]

Expected Behavior

{a: 0} => {}
#=> {:a=>0}: {:a=>0} is not empty (NoMatchingPatternError)

Actual Behavior

{a: 0} => {}
=> nil

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions