Skip to content

Commit f8c7dc1

Browse files
authored
Add "since PHP 8.1" to ReflectionXxx::setAccessible() deprecations (php#20555)
1 parent 6afe2ce commit f8c7dc1

File tree

4 files changed

+16
-16
lines changed

4 files changed

+16
-16
lines changed

ext/reflection/php_reflection.stub.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -226,7 +226,7 @@ public function getPrototype(): ReflectionMethod {}
226226
public function hasPrototype(): bool {}
227227

228228
/** @tentative-return-type */
229-
#[\Deprecated(since: '8.5', message: "as it has no effect")]
229+
#[\Deprecated(since: '8.5', message: "as it has no effect since PHP 8.1")]
230230
public function setAccessible(bool $accessible): void {}
231231
}
232232

@@ -543,7 +543,7 @@ public function getDeclaringClass(): ReflectionClass {}
543543
public function getDocComment(): string|false {}
544544

545545
/** @tentative-return-type */
546-
#[\Deprecated(since: '8.5', message: "as it has no effect")]
546+
#[\Deprecated(since: '8.5', message: "as it has no effect since PHP 8.1")]
547547
public function setAccessible(bool $accessible): void {}
548548

549549
/** @tentative-return-type */

ext/reflection/php_reflection_arginfo.h

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

ext/reflection/tests/ReflectionMethod_setAccessible.phpt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -47,13 +47,13 @@ A::aProtected
4747
A::aProtectedStatic
4848
A::aProtectedStatic
4949

50-
Deprecated: Method ReflectionMethod::setAccessible() is deprecated since 8.5, as it has no effect in %s on line %d
50+
Deprecated: Method ReflectionMethod::setAccessible() is deprecated since 8.5, as it has no effect since PHP 8.1 in %s on line %d
5151

52-
Deprecated: Method ReflectionMethod::setAccessible() is deprecated since 8.5, as it has no effect in %s on line %d
52+
Deprecated: Method ReflectionMethod::setAccessible() is deprecated since 8.5, as it has no effect since PHP 8.1 in %s on line %d
5353

54-
Deprecated: Method ReflectionMethod::setAccessible() is deprecated since 8.5, as it has no effect in %s on line %d
54+
Deprecated: Method ReflectionMethod::setAccessible() is deprecated since 8.5, as it has no effect since PHP 8.1 in %s on line %d
5555

56-
Deprecated: Method ReflectionMethod::setAccessible() is deprecated since 8.5, as it has no effect in %s on line %d
56+
Deprecated: Method ReflectionMethod::setAccessible() is deprecated since 8.5, as it has no effect since PHP 8.1 in %s on line %d
5757
A::aPrivate
5858
A::aPrivate
5959
A::aPrivateStatic

ext/reflection/tests/ReflectionProperty_setAccessible.phpt

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -96,13 +96,13 @@ string(1) "f"
9696
string(1) "g"
9797
string(1) "h"
9898

99-
Deprecated: Method ReflectionProperty::setAccessible() is deprecated since 8.5, as it has no effect in %s on line %d
99+
Deprecated: Method ReflectionProperty::setAccessible() is deprecated since 8.5, as it has no effect since PHP 8.1 in %s on line %d
100100

101-
Deprecated: Method ReflectionProperty::setAccessible() is deprecated since 8.5, as it has no effect in %s on line %d
101+
Deprecated: Method ReflectionProperty::setAccessible() is deprecated since 8.5, as it has no effect since PHP 8.1 in %s on line %d
102102

103-
Deprecated: Method ReflectionProperty::setAccessible() is deprecated since 8.5, as it has no effect in %s on line %d
103+
Deprecated: Method ReflectionProperty::setAccessible() is deprecated since 8.5, as it has no effect since PHP 8.1 in %s on line %d
104104

105-
Deprecated: Method ReflectionProperty::setAccessible() is deprecated since 8.5, as it has no effect in %s on line %d
105+
Deprecated: Method ReflectionProperty::setAccessible() is deprecated since 8.5, as it has no effect since PHP 8.1 in %s on line %d
106106
string(1) "e"
107107
string(1) "f"
108108
string(1) "g"
@@ -120,11 +120,11 @@ string(1) "e"
120120
string(1) "f"
121121
string(1) "g"
122122

123-
Deprecated: Method ReflectionProperty::setAccessible() is deprecated since 8.5, as it has no effect in %s on line %d
123+
Deprecated: Method ReflectionProperty::setAccessible() is deprecated since 8.5, as it has no effect since PHP 8.1 in %s on line %d
124124

125-
Deprecated: Method ReflectionProperty::setAccessible() is deprecated since 8.5, as it has no effect in %s on line %d
125+
Deprecated: Method ReflectionProperty::setAccessible() is deprecated since 8.5, as it has no effect since PHP 8.1 in %s on line %d
126126

127-
Deprecated: Method ReflectionProperty::setAccessible() is deprecated since 8.5, as it has no effect in %s on line %d
127+
Deprecated: Method ReflectionProperty::setAccessible() is deprecated since 8.5, as it has no effect since PHP 8.1 in %s on line %d
128128
string(1) "e"
129129
string(1) "f"
130130
string(1) "g"

0 commit comments

Comments
 (0)