Код: Выделить всё
foreach ($row['bgcolor'] as &$colBgColor) {
$colBgColor = Color::COLOR_HEADER;
}
Код: Выделить всё
PHP0421 The variable '$colBgColor' is assigned, but its value is never used
Я безуспешно пытался следовать аннотациям выше foreach :
Код: Выделить всё
@psalm-suppress PHP0421
Код: Выделить всё
@phpstan-ignore-next-line
- и @psalm-ignore-var
Код: Выделить всё
@var string $colBgColor
Код: Выделить всё
@psalm-property-write string $colBgColor
Подробнее здесь: https://stackoverflow.com/questions/791 ... r-used-php