develooper Front page | perl.perl6.language | Postings from May 2001

Re: 'is' and action at a distance

Thread Previous | Thread Next
From:
Austin Hastings
Date:
May 18, 2001 06:22
Subject:
Re: 'is' and action at a distance
Message ID:
20010518132210.2414.qmail@web1105.mail.yahoo.com

--- Damian Conway <damian@mail.csse.monash.edu.au> wrote:
 
> It's probably just a matter of coding what you actually mean. 
> In Perl 5 and 6 your version means "if $fh is true in *any* 
> possible way...", whereas you seem to want "if $fh is defined",
> which is:

Hmm. I can easily see this producing incomprehensible code when spread
across large systems. To wit, those developers used to "0 means false"
semantics seeings a scalar that they just know has a 0 in it and
wondering why the branch isn't doing what they know it should.

This will have to be addressed using a coding convention of some sort,
I suppose. What's the verbose way to query the "is true" property of a
thingy?


>    > Can 'undef' valued thingys have properties
> 
> Yes.
>    
>    > and functions?
> 
> No.

Aren't things like memoizability essentially properties? 

=Austin
 


__________________________________________________
Do You Yahoo!?
Yahoo! Auctions - buy the things you want at great prices
http://auctions.yahoo.com/

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About