Slash Boxes
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
More | Login | Reply
Loading... please wait.
  • With perl, a coderef is a subroutine, basically.  With rubies coderefs, they are more like perl's blocks:

    use feature ':5.10';
    sub foo {
       say 'beginning of foo';
       say 'ending of foo';

    sub bar {
       say 'beginning of bar';
       my @foo = grep { return } (1,2,3,4); # I'd say this should mean none
       say 'ending of bar';


    Note that the grep kills bar.