it occured to me that this is where Perl6 user exposed parsing would allow us to superimpose such features on the language seamlessly, without all the caveats inherent to Perl5 solutions.
You won't have to change the grammar or have a "parsed" trait on an operator. Every block is a closure, so something like this will work:
multi transaction (Object $object, &block) {
...;
block();
...;
}
transaction $dbh -> {
...
}
(Note: this is probably wrong, but I can't check it since I don't have a working Perl 6 interpreter :)
Juerd
# { site => 'juerd.nl', plp_site => 'plp.juerd.nl', do_not_use => 'spamtrap' }