1
0
mirror of https://github.com/danog/psalm.git synced 2024-11-27 04:45:20 +01:00
This commit is contained in:
orklah 2022-01-16 09:29:16 +01:00
parent e26e022428
commit 6578396afb

View File

@ -275,6 +275,29 @@ class ReadonlyPropertyTest extends TestCase
false,
'8.1',
],
'readonlyPhpDocPromotedPropertyAssignOperator' => [
'<?php
final class A
{
public function __construct(
/**
* @psalm-readonly
*/
private string $string,
) {
}
private function mutateString(): void
{
$this->string = "";
}
}',
'error_message' => 'InaccessibleProperty',
[],
false,
'8.1',
],
];
}
}