Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Re^2: Increment avoids warning unexpectedly

by jpeg (Chaplain)
on Jun 07, 2006 at 16:45 UTC ( #554089=note: print w/replies, xml ) Need Help??


in reply to Re: Increment avoids warning unexpectedly
in thread Increment avoids warning unexpectedly

However, the ++'s operator's magic applies to strings that =~ m/^[a-zA-Z]*[0-9]*\z/. "a,b" doesn't match.

I suspect that in the third case perl is calling int($m), which returns 0, then applying the prefix increment operator.

Code tags added by GrandFather

--
jpg

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others exploiting the Monastery: (5)
As of 2022-05-17 11:17 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Do you prefer to work remotely?



    Results (65 votes). Check out past polls.

    Notices?