New features in bleadperl

rafael on 2006-11-02T12:42:39

I added two features in bleadperl recently:

# new prototype character !
# _ is just like $, except that it defaults to $_ :
sub foo (_) {
    print "<@_>\n";
}
foo(42); # prints <42>
foo(); # equivalent to foo($_)


And another one, you can now override readpipe() :

BEGIN{
    *CORE::GLOBAL::readpipe = sub($){ ... }
}
qx/foo/; # calls the function with "foo" as argument
`foo`; # same thing