4.2.21. Remove Readonly Option¶
Readonly is a property and class option. This cobbler removes it from both.
The readonly keyword is removed from property and class definitions, and from promoted properties.
4.2.21.1. Before¶
<?php
readonly class x {
private readonly string $x;
}
?>
4.2.21.2. After¶
<?php
class x {
private string $x;
}
?>
4.2.21.3. Suggested Analysis¶
4.2.21.4. Specs¶
Short Name |
Classes/RemoveReadonly |
Exakat version |
2.3.0 |
Available in |