Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!sun-barr!newstop!texsun!convex!convex.com!tchrist From: tchrist@convex.com (Tom Christiansen) Newsgroups: comp.lang.perl Subject: defined keys that aren't defined Message-ID: <111562@convex.convex.com> Date: 17 Dec 90 06:52:17 GMT Sender: news@convex.com Reply-To: tchrist@convex.com (Tom Christiansen) Organization: Convex Computer Corp, Richardson, TX Lines: 18 I know this is beating a dead horse, and we're still waiting for Larry to emerge from his sequesterment to actually comment on this stuff, but I just discovered a pretty (to me) counter- intuitive implication that I wanted to add. @x{'a'..'g'} = (); print("keys are: ", join(", ", sort keys %x), "\n"); print((defined $x{'c'}) ? "defined" : "not defined", "\n"); This prints "not defined". Keys claims that there's a "c" element, but defined says otherwise. This seems inconsistent. I'm still looking for a useful application of this phenomenon. --tom -- Tom Christiansen tchrist@convex.com convex!tchrist "With a kernel dive, all things are possible, but it sure makes it hard to look at yourself in the mirror the next morning." -me