Darren Duncan wrote:
> Jon Lang wrote:
>> Spitballing here: you drew an analogy to the feed operators. I wonder
>> if that analogy could be taken further: use --> and <-- outside of
>> signatures as feed operators - but instead of feeding arrays back and
>> forth, have them feed capture objects and engage in some implicit
>> currying. That is:
>>
>> foo <-- $capture
>> $capture --> foo
>>
>> would both be equivalent to:
>>
>> foo :assuming(|$capture)
>>
>> ...or something to that effect. So instead of composing a series of
>> functions by nesting them in each others' argument lists, you could do
>> so by chaining them together using --> or <--.
>
> That could be interesting. But do you have an example use case or example
> code illustrating its use?
Perhaps something like:
my $name = "jonathan";
$name --> capitalize --> say;
Or:
$y = acos 'degrees' <-- sin 'radians' <-- $x;
--
Jonathan "Dataweaver" Lang