Skip to content

Commit 96b0866

Browse files
committed
PHP 8.1: Added missing tests of intersection types for LowerCaseTypeSniff
1 parent e4abe66 commit 96b0866

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

src/Standards/Generic/Tests/PHP/LowerCaseTypeUnitTest.inc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,3 +85,7 @@ class ConstructorPropertyPromotionAndNormalParams {
8585
function (): NeVeR {
8686
exit;
8787
};
88+
89+
function intersectionParamTypes (\Package\ClassName&\Package\Other_Class $var) {}
90+
91+
function intersectionReturnTypes ($var): \Package\ClassName&\Package\Other_Class {}

src/Standards/Generic/Tests/PHP/LowerCaseTypeUnitTest.inc.fixed

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,3 +85,7 @@ class ConstructorPropertyPromotionAndNormalParams {
8585
function (): never {
8686
exit;
8787
};
88+
89+
function intersectionParamTypes (\Package\ClassName&\Package\Other_Class $var) {}
90+
91+
function intersectionReturnTypes ($var): \Package\ClassName&\Package\Other_Class {}

0 commit comments

Comments
 (0)