Skip to editor
Psalm
Docs
Playground
Plugins
Blog
Paid support
Share
Fix issues
Show original
PHP
Settings
<?php class Foo { public function doSomething() : void {} } /** * @psalm-assert-if-true Foo $bar */ function isFoo(object $bar) : bool { return $bar instanceof Foo; } function isItFoo(object $maybeFoo) : void { if (isFoo($maybeFoo)) { $maybeFoo->doSomething(); // this is fine } $maybeFoo->doSomething(); // this is not }
Issues
Types
idle
Saved Jan 23 2019 05:57 UTC
⌘/Ctrl+Enter
run
⌘/Ctrl+S
share
F8
/
⇧F8
next/prev issue