develooper Front page | perl.perl5.porters | Postings from November 2003

Re: $^E bug and perl 5.8.0

Thread Previous | Thread Next
From:
Dan Sugalski
Date:
November 19, 2003 08:08
Subject:
Re: $^E bug and perl 5.8.0
Message ID:
Pine.LNX.4.58.0311191109570.7503@sprite.sidhe.org
On Wed, 19 Nov 2003, Rafael Garcia-Suarez wrote:

> Dan Sugalski wrote:
> > Basically you're using a variable that can be affected by external things
> > in a way that pretty much guarantees that external things will be
> > happening. That it changes isn't much of a surprise. ($!/$^E may get
> > modified by some signal handlers too, depending on what you do, so there's
> > not even any guarantee that "$^E = 42; $^E++;" will end up with $^E set to
> > 43.
>
> Using the Mac OS X equivalent of truss/strace might help to find out
> why errno changes there.

My bet would be that the print triggers an errno update, which strikes me
as perfectly reasonable. A syscall could be the result there, and syscalls
can twiddle errno if they want to. A bit excessive if nothing goes wrong,
perhaps, but not out of order.

					Dan

--------------------------------------"it's like this"-------------------
Dan Sugalski                          even samurai
dan@sidhe.org                         have teddy bears and even
                                      teddy bears get drunk


Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About