From 45d68ff5d6ed6a38dd302832cf0dc2054e035710 Mon Sep 17 00:00:00 2001 From: JJ Merelo Date: Sat, 30 Jun 2018 10:30:40 +0200 Subject: [PATCH] Revising Any.skip and Any.batch In fact, they were done already. I have only added some clarification. This closes #1195 --- doc/Type/Any.pod6 | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/doc/Type/Any.pod6 b/doc/Type/Any.pod6 index bd29872d0..580eecd7a 100644 --- a/doc/Type/Any.pod6 +++ b/doc/Type/Any.pod6 @@ -602,6 +602,11 @@ Defined as: Creates a L from 1-item list's iterator and uses L«C|/type/Seq#method_skip» on it. +You can apply them to classes too, resulting in empty lists or lists that +contain a single class. This is not a real use case, and it is mostly intended +to show the calling syntax. Please note that calling C without argument is +equivalente to C. + say Any.skip; # OUTPUT: «()␤» say Any.skip(5); # OUTPUT: «()␤» say Any.skip(-1); # OUTPUT: «((Any))␤» @@ -1010,7 +1015,7 @@ Defined as: multi method batch(Int:D $batch --> Seq) multi method batch(Int:D :$elems --> Seq) -Coerces the C to a C by applying the C<.list> method and uses +Coerces the object to a C by applying the C<.list> method and uses L«C|/type/List#method_batch» on it. =end pod