more useful options | |
PerlMonks |
Re: Re: How to map a directory tree to a perl hash treeby Rudif (Hermit) |
on Mar 11, 2001 at 00:52 UTC ( [id://63519]=note: print w/replies, xml ) | Need Help?? |
AVOID STRING EVAL I will. I did have an inkling that a solution involving multiple references to the same data item (a nascent hash entry), perhaps combined with recursion, should be possible, but I could not see how it would fit together. But then as I wrote some test cases, initializing multilevel hashes, it dawned on me that I could construct similar Perl code on the fly and eval it - my first ever creative use for string eval. I must admit, I took the easy way out .-( I probably cost me a --, but I'm wiling to pay my way. Rudif
In Section
Seekers of Perl Wisdom
|
|