1
0
mirror of https://github.com/php/doc-en.git synced 2026-03-24 15:52:15 +01:00

Reflection(Property|Method)::setAccessible() no longer has effect

Cf. <https://wiki.php.net/rfc/make-reflection-setaccessible-no-op>.
This commit is contained in:
Christoph M. Becker
2021-11-26 21:03:53 +01:00
parent c140370c35
commit 7b6a20ed5d
2 changed files with 10 additions and 0 deletions

View File

@@ -16,6 +16,11 @@
<para>
Enables invoking of a protected or private method via the <methodname>ReflectionMethod::invoke</methodname> method.
</para>
<note>
<simpara>
As of PHP 8.1.0, calling this method has no effect; all methods are invokable by default.
</simpara>
</note>
</refsect1>
<refsect1 role="parameters">

View File

@@ -17,6 +17,11 @@
Enables access to a protected or private property via the <methodname>ReflectionProperty::getValue</methodname> and
<methodname>ReflectionProperty::setValue</methodname> methods.
</para>
<note>
<simpara>
As of PHP 8.1.0, calling this method has no effect; all properties are accessible by default.
</simpara>
</note>
</refsect1>
<refsect1 role="parameters">