Skip to content

until gives default value if expression is never matched in array #1

@ajusa

Description

@ajusa
 [1, 2, 4].assertMatch([until 3, @a, .._]); echo a

In this case, 3 doesn't appear in the array so I'd expect it to not match. Instead, this prints 0 for some reason - does it just fail to find a match, so the default value for the type is used instead?

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