File tree Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Original file line number Diff line number Diff line change @@ -555,6 +555,20 @@ Creates a supply that emits a Range every time a new minimum or maximum
555
555
values is seen from the given supply. The optional parameter specifies
556
556
the comparator, just as with Any.max.
557
557
558
+ = head2 method skip
559
+
560
+ method skip(Supply:D: Int(Cool) $number = 1 --> Supply:D)
561
+
562
+ Returns a new C < Supply > which will emit all values from the given C < Supply >
563
+ except for the first C < $number > values, which will be thrown away.
564
+
565
+ = for code
566
+ my $supplier = Supplier.new;
567
+ my $supply = $supplier.Supply;
568
+ $supply = $supply.skip(3);
569
+ $supply.tap({ say $_ });
570
+ $supplier.emit($_) for 1..10; # OUTPUT: «45678910»
571
+
558
572
= head2 method start
559
573
560
574
method start(Supply:D: &startee --> Supply:D)
You can’t perform that action at this time.
0 commit comments