![]() |
|
There's more than one way to do things | |
PerlMonks |
comment on |
( #3333=superdoc: print w/replies, xml ) | Need Help?? |
> I don't really see a win with this style, though, over giving test a parameter, and just using standard function calls (I had a little play with coroutines on the way but that's really overkill for this).
Well I expected decorators to be more flexible, i.e. to redefine test() by putting a wrapper around it and not to built a new decorator @test (!?!) But I'm not too proficient with Python, and I'm misunderstanding the code. (well, there must be a reason why I prefer Perl's syntactic flexibility. ;-) I suppose def _(a) is a way to workaround the limitations of lamda? Is the name _ special (magic) or is it just a convention?
Cheers Rolf ( addicted to the Perl Programming Language) In reply to Re^6: RFC: Simulating Ruby's "yield" and "blocks" in Perl (Python)
by LanX
|
|