Permalink
Browse files

Change the listless map into a Whatever map

  • Loading branch information...
lizmat committed Nov 26, 2013
1 parent 80eaa3c commit 0f9df8a0f229d617abe810bd9af2768a48a3fe2b
Showing with 12 additions and 3 deletions.
  1. +12 −3 S32-setting-library/Containers.pod
@@ -345,9 +345,18 @@ if you mean the other thing.
In some situations, specifically with concurrent processes, the return
values of a C<map> may not directly relate to a list of values: in that
-case it is possible to specify a map B<without> values: this will then
-effectively be a lazy loop returning values until it is exited with C<last>.
-This may be a cheaper alternative to a C<gather>, C<loop>, C<take> setup.
+case it is possible to specify a map with just a C<Whatever>:
+
+ map { # actual implementation of Channel.list
+ winner $self {
+ more * { $_ }
+ done * { last }
+ }
+ }, *;
+
+This effectively becomes a lazy loop returning values until it is exited with
+C<last>. This may be a cheaper alternative to a C<gather>, C<loop>, C<take>
+setup.
=item duckmap

0 comments on commit 0f9df8a

Please sign in to comment.