undef and ref to undef
sthoenna at efn.org
Thu Jun 19 07:25:30 BST 2008
On Wed, June 18, 2008 5:10 am, Peter Corlett wrote:
> On Wed, Jun 18, 2008 at 12:44:48PM +0100, Ian Docherty wrote:
>> Why would someone return \undef rather than undef from a
>> function/method and what is the advantage? Just something I came across
>> recently that seemed rather odd.
> IIRC, \undef is the lowest-overhead true value, so it may be a misguided
> attempt to save memory.
Very cute. Though I think Nicholas made 1 just as cheap in 5.10?
Reminds me of mysql's 1-bit boolean "varchar(0) null" type.
More information about the london.pm