in reply to Re: To be, or not to be, an object ?
in thread To be, or not to be, an object ?

There are, 2 aspects to the differences between my attempt and Grahams' (author of Scalar::Util), Graham...
  • creates a temporary method in the UNIVERSAL class

Scalar::Util uses UNIVERSAL::a_sub_not_likely_to_be_here, but it's not a temporary method, because (unless I'm mistaken) it stays in the UNIVERSAL namespace forever.

However, the XS version of Scalar::Util is pretty straightforward, it's blessed() does not use any dirty tricks at all, it just determines whether something is blessed, using the appropriate API.

Replies are listed 'Best First'.
Re^3: To be, or not to be, an object ?
by Bloodnok (Vicar) on Jul 24, 2008 at 14:33 UTC
    TFT, point taken.

    I would point out that temporary and forever are one and the same in this context i.e. the lifetime of the program useing Scalar::Utils.

    At last, a user level that overstates my experience :-))