From ac52cb8739ecbd667b6a71a4decdc125bd3b581c Mon Sep 17 00:00:00 2001 From: Rodrigo Primo Date: Wed, 27 May 2026 14:15:39 +0000 Subject: [PATCH] Add Section 4.10 entry to the PER-CS 2.0 to 3.0 migration guide PER-CS 3.0 added a new Section 4.10 ("Interface and abstract properties") covering abstract properties in interfaces and abstract classes. It was introduced by #108. The migration guide had no mention of Section 4.10. This commit adds a new entry matching the format used for other wholly-new sections in the migration guide (e.g., Section 10, Section 11, Section 12 in migration-2.0.md): a brief introduction pointing readers at the spec, followed by example code blocks. --- migration-3.0.md | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/migration-3.0.md b/migration-3.0.md index 409a868..2968e4c 100644 --- a/migration-3.0.md +++ b/migration-3.0.md @@ -129,6 +129,30 @@ class Example } ``` +## [Section 4.10 - Interface and abstract properties](https://www.php-fig.org/per/coding-style/#410-interface-and-abstract-properties) + +This is a new section about interface and abstract properties, as per the link above. Examples follow: + +```php +abstract class Example { + abstract public string $name { + get => ucfirst($this->name); + set; + } +} +``` + +```php +interface Example +{ + public string $readable { get; } + + public string $writeable { set; } + + public string $both { get; set; } +} +``` + ## [Section 5.2 - Switch, Case, and Match](https://www.php-fig.org/per/coding-style/#52-switch-case-match) When breaking a series of boolean operators across multiple lines, the operator MUST be at the beginning of each line, not the end of each line.