File tree Expand file tree Collapse file tree 1 file changed +14
-3
lines changed Expand file tree Collapse file tree 1 file changed +14
-3
lines changed Original file line number Diff line number Diff line change @@ -602,9 +602,20 @@ Defined as:
602
602
603
603
method flatmap(&block, :$label)
604
604
605
- N < This method is deprecated in 6.d and will be removed in 6.e >
606
- Applies L < C < map > |/type/Any#method_map> to every element with the block and label
607
- used as an argument and flattens out the result using C < .flat > .
605
+ B < DEPRECATION NOTICE > : This method is deprecated in 6.d and will be removed in
606
+ 6.e. Use C < .map > followed by C < .flat > instead.
607
+
608
+ Applies L < C < map > |/type/Any#method_map> to every element with the block and
609
+ C < Label > used as an argument and flattens out the result using C < .flat > .
610
+
611
+ say "aabbccc".comb.Mix.flatmap: "→ " ~ *; # OUTPUT: «(→ b␉2 → c␉3 → a␉2)»
612
+
613
+ In this case, the elements of the C < Mix > are itemized to key␉value, and then
614
+ mapped and flattened. Same result as
615
+
616
+ say "aabbccc".comb.Mix.map( "→ " ~ * ).flat
617
+
618
+ Which is why it is deprecated in 6.d and will be eventually eliminated in 6.e.
608
619
609
620
= head2 method roll
610
621
You can’t perform that action at this time.
0 commit comments