Skip to content

Pattern matching #1

Open
Open
@thekid

Description

@thekid

Rough draft:

// Type checks, already possible today
$value is int;

// Literal checks
$value is 1;

// Omitting values
$value is [, $second];

// Deconstruction 
$value is Person(name: $name);

See also:

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestquestionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions