Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re^3: Wrong idioms

by tobyink (Abbot)
on Mar 30, 2013 at 21:16 UTC ( #1026300=note: print w/ replies, xml ) Need Help??


in reply to Re^2: Wrong idioms
in thread Wrong idioms

"Also - what other languages treat '0' as false?"

It would be horrible if "0" were treated as true, given that the integer 0 is false and Perl silently converts between strings and numbers.

What other languages? PHP does.

package Cow { use Moo; has name => (is => 'lazy', default => sub { 'Mooington' }) } say Cow->new->name


Comment on Re^3: Wrong idioms
Select or Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1026300]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (14)
As of 2015-07-31 00:47 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (274 votes), past polls