diff --git a/stubs/Reflection.phpstub b/stubs/Reflection.phpstub index a82681c86..663557039 100644 --- a/stubs/Reflection.phpstub +++ b/stubs/Reflection.phpstub @@ -126,18 +126,13 @@ class ReflectionParameter { /** * @psalm-immutable - * @since 8.0 */ class ReflectionNamedType extends ReflectionType { - /** - * @since 8.0 - */ public function getName(): string {} /** * @psalm-assert-if-false class-string $this->getName() - * @since 8.0 */ public function isBuiltin(): bool {} } diff --git a/tests/AssertAnnotationTest.php b/tests/AssertAnnotationTest.php index e828428cf..2e51d5859 100644 --- a/tests/AssertAnnotationTest.php +++ b/tests/AssertAnnotationTest.php @@ -1465,13 +1465,14 @@ class AssertAnnotationTest extends TestCase ], 'reflectionNameTypeClassStringIfNotBuiltin' => [ 'getType(); return ($type instanceof \ReflectionNamedType) && !$type->isBuiltin() ? $type->getName() : null; - }' + }', + [], + [], + '7.4', ], 'withHasTypeCall' => [ '