in reply to Re: Autoincrement operator precedence difference between C and Perl
in thread Autoincrement operator precedence difference between C and Perl

While your observations are most probably correct, it stands as a fact that evaluation order of multiple pre/post-increments in one statement isn't explicitly defined in Perl 5, I guess on purpose. It is an artifact of the implementation of Perl - it is not in the language specs afaik - so you shouldn't rely on it, even if all perl 5 binaries we know of stack execution in the way you describe.

And that is more than saying "while you can use multiple pre/post-increments in a single statement, it is bad practice and should be avoided" - it is saying "it's not defined. Don't".

--shmem

_($_=" "x(1<<5)."?\n".q·/)Oo.  G°\        /
                              /\_¯/(q    /
----------------------------  \__(m.====·.(_("always off the crowd"))."·
");sub _{s./.($e="'Itrs `mnsgdq Gdbj O`qkdq")=~y/"-y/#-z/;$e.e && print}
  • Comment on Re^2: Autoincrement operator precedence difference between C and Perl