|Problems? Is your data what you think it is?|
One Sigil to Hack them All . . .by erikharrison (Deacon)
|on May 07, 2002 at 20:30 UTC||Need Help??|
Sigils are hard to teach . . . very useful once you get someone to understand them, but that first step can be hard.
So why not get rid of them? That's what I set out to do, but instead wound up with STUPID (Sigils Turned Unified . . . uh . . . PID). STUPID will turn all four of Perl's sigils to the ampersand: &. You must assign to these variable in a more Python/Ruby - ish idiom, much like constructing anonymous arrays and hashes. In fact you are. They no londer interpolate in double quoted strings, and the implementation doesn't always work, AND you have to explicity dereference arrays/hashes. I couldn't think where this should really belong, but I figured this was the closest place in the Monestary. Enjoy, and don't take seriously.
ps. Yes I am aware that it uses sim-refs . . . it's just a joke man :-)
pps - Here's how to use this little gizmo . . .
UPDATE:Alright! I don't know if anyone will ever read this, but just in case, it should be noted that Perl 5.8 fixes the problem with lvalue AUTOLOAD which required that you use the & funny character. Now this little snippet truly eliminates sigils entirely. I think. I actually haven't been able to test it, 'cause my computer is broken. /msg me if it works