in reply to Re^5: "last expression" quiz
in thread "last expression" quiz

Ah, interesting; I guess Perl DWIMs this so well I had never paid enough attention to notice the subtlety. Reminds me of the games some people played elsewhere on the Monastery quite a while ago with scalars that had specific, different values when evaluated as numbers or as strings (without overloading, if memory serves). (Alas, I cannot remember any useful keywords to Super Search it.)

Makeshifts last the longest.

Replies are listed 'Best First'.
Re^7: "last expression" quiz
by chromatic (Archbishop) on Oct 20, 2005 at 06:46 UTC

      Yes, that’s precisely the kind of thing I’m talking about. The nodes I am thinking of predate Scalar::Util and instead used a bit of voodoo to achieve the effect, though.

      And thanks for pointing me that way – I didn’t know Scalar::Util had such a utility function. Plus now I see several new interesting functions in recent versions that I hadn’t noticed before. I need to do some homework here!

      Makeshifts last the longest.