Welcome to the Monastery | |
PerlMonks |
Re^4: Declaring with my, assigning, and testing in same line (attributes)by LanX (Saint) |
on Dec 13, 2015 at 14:53 UTC ( [id://1150165]=note: print w/replies, xml ) | Need Help?? |
> I'm fine with using tie as long as I can untie when I'm done. Otherwise the penalty for this syntactic sugar would be to huge. At second thought this is a too limited technique... consider
The check would be done only once, so in this case I'd clearly prefer a functional approach
Using attributes is a pretty way to apply ties, but most use cases I can think of combining this with untie are limited to debugging. > > > And for completeness , I'm sure you could also use variable :attributes for such checks. Wrong I was, young padawan. ;-)
Cheers Rolf
In Section
Seekers of Perl Wisdom
|
|