We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
As in my example, using the class constant works, but using the constant directly from an instance does not work.
https://psalm.dev/r/496e0e40cc
The text was updated successfully, but these errors were encountered:
I found these snippets:
<?php class Foo { public const BAR = 'bar'; } $foo = new Foo(); $workingArray = ['foo' => 'bar', Foo::BAR => 'baz']; $brokenArray = ['foo' => 'bar', $foo::BAR => 'baz'];
Psalm output (using commit b618313): INFO: MixedArrayOffset - 10:16 - Cannot create mixed offset – expecting array-key
Sorry, something went wrong.
Simplified: https://psalm.dev/r/d3471853a2
<?php class Foo { public const BAR = 'bar'; } $foo = new Foo(); /** @psalm-trace $_trace */ $_trace = $foo::BAR;
Psalm output (using commit b618313): INFO: Trace - 10:1 - $_trace: mixed
Successfully merging a pull request may close this issue.
As in my example, using the class constant works, but using the constant directly from an instance does not work.
https://psalm.dev/r/496e0e40cc
The text was updated successfully, but these errors were encountered: