Created
December 27, 2011 19:23
-
-
Save Benabik/1524863 to your computer and use it in GitHub Desktop.
Comb proxy attempt
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
my @a; | |
my $a := { | |
my $temp; | |
Proxy.new( | |
FETCH => method { return $temp; }, | |
STORE => method ($val) { $temp = $val; @a = $val.comb } | |
); | |
}(); | |
$a = 'test'; | |
say $a; | |
say @a; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment