Author: ruoso Date: 2008-11-28 19:38:22 +0100 (Fri, 28 Nov 2008) New Revision: 24104
Modified: docs/Perl6/Spec/S07-iterators.pod Log: [spec] anything that behaves like a list might implement .Iterator(). And the name is really .Iterator(), not .iterator(); Modified: docs/Perl6/Spec/S07-iterators.pod =================================================================== --- docs/Perl6/Spec/S07-iterators.pod 2008-11-28 18:30:32 UTC (rev 24103) +++ docs/Perl6/Spec/S07-iterators.pod 2008-11-28 18:38:22 UTC (rev 24104) @@ -115,8 +115,7 @@ =head1 The Iterator Role -The iterator role represents the lazy access to a list, walking through -one of: +The iterator role represents the lazy access to a list, walking through: =over @@ -126,15 +125,17 @@ =item Stream (mostly for IO) +=item In fact, any value that wants to behave like a list + =back It's important to realize that the iterator of a list can be accessed -by the .iterator() method (but only the runtime will be calling that +by the .Iterator() method (but only the runtime will be calling that most of the time), and the implemenation of each iterator is private to the list and implementation specific. This is a minimal API that should allow custom iterator -implemenations, but this spec should be expanded in the future to +implementations, but this spec should be expanded in the future to provide additional API for batch-aware iterators. The methods in this role are: