@@ -830,11 +830,11 @@ other things use the concept as well. For example, an un-reified L<Range> is jus
830
830
the two end points. In some languages, calculating the sum of a huge range is a
831
831
lengthy and memory-consuming process, but Perl 6 calculates it instantly:
832
832
833
- say sum 1 ..9_999_999_999_999; # OUTPUT: «49999999999995000000000000»
833
+ say sum 1 .. 9_999_999_999_999; # OUTPUT: «49999999999995000000000000»
834
834
835
- Why? Because the sum can be calculated I < without > reifying the Range; that is
835
+ Why? Because the sum can be calculated I < without > reifying the Range; that is,
836
836
without figuring out all the elements it contains. This is why this feature
837
- exists. You can even make your own things you can reify-on-demand, using
837
+ exists. You can even make your own things reify-on-demand, using
838
838
L « C < gather > and C < take > |/syntax/gather%20take» :
839
839
840
840
my $seq = gather {
@@ -859,10 +859,10 @@ L«C<gather> and C<take>|/syntax/gather%20take»:
859
859
# (1 2)
860
860
861
861
Following the output above, you can see the print statements I < inside > the
862
- C < gather > got printed only when we reified the individual elements while looking
863
- up an element. Also note, the elements got reified just once. When we printed
862
+ C < gather > got executed only when we reified the individual elements while looking
863
+ up an element. Also note that the elements got reified just once. When we printed
864
864
the same elements again on the last line of the example, the messages inside
865
- C < gather > we no longer printed. This is because the construct used
865
+ C < gather > was no longer printed. This is because the construct used
866
866
already-reified elements from the L < Seq > 's cache.
867
867
868
868
Note that above we assigned the C < gather > to a L < Scalar > container (the C < $ >
0 commit comments