note 99226 added to class.iteratoraggregate
| From: | tmont at osu1 dot php dot net | Date: | Thu, 05 Aug 2010 02:30:19 +0000 |
| Subject: | note 99226 added to class.iteratoraggregate | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-171374@lists.php.net to get a copy of this message | ||
Note that you cannot have a class that implements both Iterator and IteratorAggregate. I'm sure
the reason is non-ludicrous, but I can't imagine what that might be.
> php -r "class Foo implements Iterator, IteratorAggregate {}"
> Fatal error: Class Foo cannot implement both IteratorAggregate and Iterator at the same time
They should add a trollface to the end of that error message.
----
Server IP: 69.147.83.197
Probable Submitter: 70.179.43.152
----
Manual Page -- http://www.php.net/manual/en/class.iteratoraggregate.php
Edit -- https://master.php.net/note/edit/99226
Del: integrated -- https://master.php.net/note/delete/99226/integrated
Del: useless -- https://master.php.net/note/delete/99226/useless
Del: bad code -- https://master.php.net/note/delete/99226/bad+code
Del: spam -- https://master.php.net/note/delete/99226/spam
Del: non-english -- https://master.php.net/note/delete/99226/non-english
Del: in docs -- https://master.php.net/note/delete/99226/in+docs
Del: other reasons-- https://master.php.net/note/delete/99226
Reject -- https://master.php.net/note/reject/99226
Search -- https://master.php.net/manage/user-notes.php