Skip to content
New issue

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

clearstatcache 2nd argument is unused if 1st arg is not true should report error #11084

Open
kkmuffme opened this issue Aug 26, 2024 · 1 comment

Comments

@kkmuffme
Copy link
Contributor

https://psalm.dev/r/bfc378fb62

The 2nd arg is only used if the first argument is true.
If the 1st arg is false, it should report an error if a 2nd arg is passed.

https://www.php.net/manual/en/function.clearstatcache.php

filename
Clear the realpath cache for a specific filename only; only used if clear_realpath_cache is true.

Copy link

I found these snippets:

https://psalm.dev/r/bfc378fb62
<?php

clearstatcache( false, 'foo.xml' );
Psalm output (using commit 16b24bd):

No issues!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant