Skip to content

assignment of a non backed enum to curl option should error #13615

@staabm

Description

@staabm

Bug report

even though we know the types of curl constants like e.g. CURLOPT_CUSTOMREQUEST we don't error about invalid values passed into them via curl_setopt_array

Code snippet that reproduces the problem

https://phpstan.org/r/5a37e3ac-354d-49cb-93d8-e9079863c140

Expected output

a error that you cannot pass a non-backed enum into a curl option which expects a string or null

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

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions