> As you can see, perl simplified your unquoted numerical strings > by dropping the > leading zeros *before* stringifying them to use as hash keys. Quoting them > explicitly solves the problem.
Actually, Perl interprets the values with leading zeros as octal numbers; that's why 00056 became 46. > I admit I'm a little surprised by this behavior. > The auto-quoting function of => > doesn't work quite as literally as I thought. It's working exactly as documented; => automatically quotes barewords, i.e., words that have no other meaning in the language. Strings of digits represent numbers in Perl, hence the hash keys must be quoted explicitly to be treated as text strings. In general, if your hash key is text that does not start with a letter or underscore, you should quote it yourself. If the hash key is text that contains anything but letters, digits, and underscores, you *must* quote it yourself. (There are some exceptions, but this approach is much less error-prone.) -- Eric Amick Columbia, MD _______________________________________________ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs