in reply to Re^12: Setting signal handlers considered unsafe? (OT: C++)
in thread Setting signal handlers considered unsafe?

The point was to show what Perl does. I specifically mentioned the result was specific to my compiler.

The standard specifically states that modifying a variable more than once in the same statement results in either undefined or implementation defined behavior (depending on what is actually being done).

I believe foo(x++, x) is also undefined even though it only modifies the variable once.

Basically, the same thing applies to Perl. While the order is predictable, relying on it is dangerous. I've seen the following a fair bit, though, which modifies and uses @_:

sub foo { shift->bar(@_) }