| Conditions | 3 | 
| Paths | 2 | 
| Total Lines | 12 | 
| Code Lines | 6 | 
| Lines | 0 | 
| Ratio | 0 % | 
| Changes | 1 | ||
| Bugs | 0 | Features | 0 | 
| 1 | <?php  | 
            ||
| 26 | *  | 
            ||
| 27 | * @return static  | 
            ||
| 28 | *  | 
            ||
| 29 | * @psalm-suppress UnsafeInstantiation  | 
            ||
| 30 | * @phpstan-ignore-next-line  | 
            ||
| 31 | */  | 
            ||
| 32 | #[\ReturnTypeWillChange]  | 
            ||
| 33 | public static function __callStatic(string $name, array $arguments)  | 
            ||
| 34 |     { | 
            ||
| 35 |         try { | 
            ||
| 36 | $class = new \ReflectionClassConstant(static::class, $name);  | 
            ||
| 37 |         } catch (\ReflectionException $th) { | 
            ||
| 38 |             throw new \Error('Undefined constant ' . static::class . '::' . $name); | 
            ||
| 45 | 
This check compares calls to functions or methods with their respective definitions. If the call has more arguments than are defined, it raises an issue.
If a function is defined several times with a different number of parameters, the check may pick up the wrong definition and report false positives. One codebase where this has been known to happen is Wordpress. Please note the @ignore annotation hint above.