Skip to content

Instantly share code, notes, and snippets.

@pmichaud
Created September 3, 2009 05:13
Show Gist options
  • Save pmichaud/180138 to your computer and use it in GitHub Desktop.
Save pmichaud/180138 to your computer and use it in GitHub Desktop.
sub foo() {
my $*VAR ::= 'foo';
-> { say $*VAR; }
}
my $a = foo();
{
my $*VAR ::= 'outer';
$a(); # outputs 'outer'
}
$a(); # $*VAR not found ?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment