Re: Bug in namespaces and type hints
| From: | Felipe Pena | Date: | Mon, 10 Nov 2008 12:14:17 +0000 |
| Subject: | Re: Bug in namespaces and type hints | ||
| References: | 1 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-41817@lists.php.net to get a copy of this message | ||
2008/11/9 Marcin Kurzyna <m.kurzyna@crystalpoint.pl>:
> Hi,
> recent change in namespace code introduced new bug, please consider:
>
> <?php
> namespace tests;
>
> class t1 {
> function abc(\stdClass $std = null) {
> }
> }
> ?>
>
> triggers "Fatal error: Default value for parameters with a class type hint can only be
> NULL" where the same w/o namespace definition works as
> expected (no error).
>
> this is tested with currently newest snap: 2008.11.09 23:30 (UTC)
>
> I haven't filed bug report for this yet i'll do it if required.
>
Nice Marcin!
I have added 4 new tests about that issue, that wasn't detected with
the current tests.
Thanks.
--
Regards,
Felipe Pena.