RE: [PHP-DEV] What is the use of the $replacement property in the RegexIterator class.
| From: | Jared Williams | Date: | Thu, 06 May 2010 01:09:43 +0000 |
| Subject: | RE: [PHP-DEV] What is the use of the $replacement property in the RegexIterator class. | ||
| References: | 1 | Groups: | php.doc php.internals |
| Request: | Send a blank email to internals+get-48226@lists.php.net to get a copy of this message | ||
> -----Original Message-----
> From: Richard Quadling [mailto:rquadling@googlemail.com]
> Sent: 05 May 2010 17:26
> To: PHP internals; PHP Documentation List
> Subject: [PHP-DEV] What is the use of the $replacement
> property in the RegexIterator class.
>
> Hi.
>
> I'm in the process of getting the PHPDoc classes showing the
> correct inherited properties and methods (public/protected
> but not private).
>
> I picked RecursiveRegexIterator (it has the largest number of
> xi:includes in the documentation) as a test.
>
> Using php --rc I see that the inheritance chain is
> RecursiveRegexIterator, RegexIterator, FilterIterator and
> IteratorIterator.
>
> The property $replacement is part of RegexIterator.
>
> I can see no documentation for this in phpdoc, nor in the
> Doxygen at http://www.php.net/~helly/php/ext/spl/
>
>
> In all the examples I've made so far, var_dump()-ing the
> RegexIterator results in a ["replacement"]=>NULL
>
> Assigning a value to $replacement seems to have no bearing on
> the output.
>
> Regards,
>
> Richard.
>
>
Does seem odd public property. Guessing it's a bug.
http://www.php.net/~helly/classbrowser/?class=RecursiveRegexIterator
Jared