mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-16 00:48:54 +00:00
Added a remark about overloaded properties and language constructs (Bug #43936)
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@304662 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
parent
453bc9c8d7
commit
606c44a528
1 changed files with 14 additions and 0 deletions
|
@ -144,6 +144,20 @@
|
|||
</para>
|
||||
</note>
|
||||
|
||||
<note>
|
||||
<para>
|
||||
It is not possible to use overloaded properties in other
|
||||
language constructs than <function>isset</function>. This
|
||||
means if <function>empty</function> is called on an overloaded
|
||||
property, the overloaded method is not called.
|
||||
</para>
|
||||
<para>
|
||||
To workaround that limitation, the overloaded property must
|
||||
be copied into a local variable in the scope and then be
|
||||
handed to <function>empty</function>.
|
||||
</para>
|
||||
</note>
|
||||
|
||||
<example>
|
||||
<title>
|
||||
Overloading properties via the <function>__get</function>,
|
||||
|
|
Loading…
Reference in a new issue