diff --git a/CHANGELOG.md b/CHANGELOG.md index 0de55e2..6ad0c02 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,4 @@ +* Added @phpstan-require-implements constraints * Made PHP8.1 minimum version ## v0.1.2 (2023-09-26) diff --git a/src/Manifest/DisableableTrait.php b/src/Manifest/DisableableTrait.php index 0678d52..3be61c7 100644 --- a/src/Manifest/DisableableTrait.php +++ b/src/Manifest/DisableableTrait.php @@ -9,6 +9,9 @@ namespace DecodeLabs\Tightrope\Manifest; +/** + * @phpstan-require-implements Disableable + */ trait DisableableTrait { protected bool $disabled = false; diff --git a/src/Manifest/ImmutableTrait.php b/src/Manifest/ImmutableTrait.php index d1af873..28a5c9d 100644 --- a/src/Manifest/ImmutableTrait.php +++ b/src/Manifest/ImmutableTrait.php @@ -9,6 +9,9 @@ namespace DecodeLabs\Tightrope\Manifest; +/** + * @phpstan-require-implements Immutable + */ trait ImmutableTrait { protected bool $immutable = false; diff --git a/src/Manifest/NullableTrait.php b/src/Manifest/NullableTrait.php index 2ddaa17..28e0a37 100644 --- a/src/Manifest/NullableTrait.php +++ b/src/Manifest/NullableTrait.php @@ -9,6 +9,9 @@ namespace DecodeLabs\Tightrope\Manifest; +/** + * @phpstan-require-implements Nullable + */ trait NullableTrait { protected bool $nullable = false; diff --git a/src/Manifest/ReadOnlyableTrait.php b/src/Manifest/ReadOnlyableTrait.php index 398194d..7a28799 100644 --- a/src/Manifest/ReadOnlyableTrait.php +++ b/src/Manifest/ReadOnlyableTrait.php @@ -9,6 +9,9 @@ namespace DecodeLabs\Tightrope\Manifest; +/** + * @phpstan-require-implements ReadOnlyable + */ trait ReadOnlyableTrait { protected bool $readOnly = false; diff --git a/src/Manifest/ReadableTrait.php b/src/Manifest/ReadableTrait.php index 258b14a..d5c98f5 100644 --- a/src/Manifest/ReadableTrait.php +++ b/src/Manifest/ReadableTrait.php @@ -9,6 +9,9 @@ namespace DecodeLabs\Tightrope\Manifest; +/** + * @phpstan-require-implements Readable + */ trait ReadableTrait { protected bool $readable = false; diff --git a/src/Manifest/RequirableTrait.php b/src/Manifest/RequirableTrait.php index 4f0ff03..80ecfbb 100644 --- a/src/Manifest/RequirableTrait.php +++ b/src/Manifest/RequirableTrait.php @@ -9,6 +9,9 @@ namespace DecodeLabs\Tightrope\Manifest; +/** + * @phpstan-require-implements Requirable + */ trait RequirableTrait { protected bool $required = false; diff --git a/src/Manifest/WritableTrait.php b/src/Manifest/WritableTrait.php index 5505540..a0b0927 100644 --- a/src/Manifest/WritableTrait.php +++ b/src/Manifest/WritableTrait.php @@ -9,6 +9,9 @@ namespace DecodeLabs\Tightrope\Manifest; +/** + * @phpstan-require-implements Writable + */ trait WritableTrait { protected bool $writable = false;