Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re^2: Simulating Perl6 Meta/Hyper operators with pure Functional Programming

by LanX (Canon)
on Oct 01, 2013 at 22:41 UTC ( #1056548=note: print w/ replies, xml ) Need Help??


in reply to Re: Simulating Perl6 Meta/Hyper operators mit pure Functional Programming
in thread Simulating Perl6 Meta/Hyper operators with pure Functional Programming

Sub::Infix is indeed nice, really clever idea ... thanks! :)

My problem with overloading so far was that I couldn't use wantarray, i.e. an overloaded '+' always has to return a scalar.

But you don't have this problem, right?

Anyway ATM I try to find solutions which work w/o overloading to avoid potential side effects.

List::Gen for instance globally overloads the typeglob operator... 8-|

> my $iter = [@list1] |X| [@list2];

yep but the problem here is that the array are evaluated (i.e. listified) before being passed to the operator.

I'd like to be able to inspect the code block before evaluating it.

Cheers Rolf

( addicted to the Perl Programming Language)


Comment on Re^2: Simulating Perl6 Meta/Hyper operators with pure Functional Programming
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1056548]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others romping around the Monastery: (6)
As of 2014-09-21 08:35 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (168 votes), past polls