| 1 | <?php declare(strict_types = 1); | ||
| 10 | class StatusStream implements Stream | ||
| 11 | { | ||
| 12 | private $buffer = []; | ||
| 13 | |||
| 14 | /** | ||
| 15 | * @var Deferred | ||
| 16 | */ | ||
| 17 | private $readPromisor = null; | ||
| 18 | |||
| 19 | private $error = null; | ||
| 20 | private $ended = false; | ||
| 21 | |||
| 22 | private function resolveReadPromise($value): bool | ||
| 35 | |||
| 36 | public function update($status) | ||
| 42 | |||
| 43 | public function end() | ||
| 49 | |||
| 50 | public function fail(\Throwable $error) | ||
| 61 | |||
| 62 | public function read(): Promise | ||
| 82 | |||
| 83 | public function close() | ||
| 87 | } | ||
| 88 | 
This check looks for multiple assignments in successive lines of code. It will report an issue if the operators are not in a straight line.
To visualize
will produce issues in the first and second line, while this second example
will produce no issues.