Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Re: Quantum Weirdness and the Increment Operator

by Zaxo (Archbishop)
on Jun 24, 2004 at 20:53 UTC ( #369483=note: print w/replies, xml ) Need Help??


in reply to Quantum Weirdness and the Increment Operator

You can follow the results by realizing that post-increment returns a value, while pre-increment returns an alias to the variable. That makes subsequent operations of high enough precedence turn up in pieces that have already been evaluated.

There is no reason that perl must do it that way. Perl could do away with the C restriction, which is there for good C reasons, and return values for each increment operation. That would make perl do what you expected. But for forseeable perl, as has been said (and shouted), "Don't do that!"

After Compline,
Zaxo

  • Comment on Re: Quantum Weirdness and the Increment Operator

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://369483]
help
Chatterbox?
[marto]: zoiks
[erix]: yeah, that was in the pipeline for a while, not good
[erix]: more damage from Commander Covfefe
[marto]: sadly, the pipeline will be impacted. "That's a nice pipleline you have, shame if something where to happen to it..."

How do I use this? | Other CB clients
Other Users?
Others browsing the Monastery: (8)
As of 2017-12-14 21:01 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    What programming language do you hate the most?




















    Results (410 votes). Check out past polls.

    Notices?