Skip to content

Commit 8c1b577

Browse files
committed
fix arity requirements for function combinator
1 parent ac60df0 commit 8c1b577

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

doc/Type/Callable.pod6

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,10 @@ corresponding parameters.
4343
=head2 C«infix:<∘>»
4444
X<|∘,function combinator>X<|o,function combinator>
4545
46-
The function combinator C«infix:<∘>» or C«infix:<o>» combines two functions of arity one, so that the left function is called with the return value of the right function.
46+
The function combinator C«infix:<∘>» or C«infix:<o>» combines two functions, so
47+
that the left function is called with the return value of the right function.
48+
The number of return values of the right function has to match the arity of the
49+
left function.
4750
4851
sub f($p){ say 'f'; $p / 2 }
4952
sub g($p){ say 'g'; $p * 2 }

0 commit comments

Comments
 (0)