Skip to content

Tail of variadic closures/callables does not check #9699

@klimick

Description

@klimick

Bug report

Tail of varidic closures/callables does not check. It leads to runtime errors:
https://3v4l.org/J0fuM#v8.2.7

Code snippet that reproduces the problem

https://phpstan.org/r/3a7d3a30-ed8d-4eb9-b0c7-7ccca268e8a6

Expected output

Parameter #1 $f of function int_int_int_string expects
 Closure(int, int, int, string): int, Closure(int, int, int ...): int given

Did PHPStan help you today? Did it make you happy in any way?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions