1
0
mirror of https://github.com/danog/psalm.git synced 2024-11-27 04:45:20 +01:00
psalm/docs/running_psalm/issues/PossiblyUnusedMethod.md
Matthew Brown 6d09418a23
Detect unused return values (#5917)
* Detect unused return values

* Allow static-returning instance methods (presumed to be fluent)

* Make $is_used the default for Codebase::methodExists
2021-06-10 14:18:15 -04:00

253 B

PossiblyUnusedMethod

Emitted when --find-dead-code is turned on and Psalm cannot find any calls to a public or protected method.

<?php

class A {
    public function foo() : void {}
    public function bar() : void {}
}
(new A)->foo();