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

[perl #22811] Re: Assignment to $0 broken

From:
Andreas J Koenig
Date:
June 26, 2003 09:17
Subject:
[perl #22811] Re: Assignment to $0 broken
Message ID:
87he6cak5a.fsf_-_@franz.ak.mind.de
So now I send the patch as attachment that I've come up with. This
should NOT BE APPLIED to the repository as it is.

I also send the testscript that shows an interesting detail. This is
the code:

  if ($sequence) {         # all tests fail
    test_with_threads;
    test_no_threads;
  } else {                 # all tests pass
    test_no_threads;
    test_with_threads;
  }

If the script is run against a perl with my patch applied, all depends
on the sequence. If the first assignment to $0 is done in the main
thread, all goes well, even the threaded test. But if the threaded
test is run first, then subsequent assignments in the main thread
break.

I hope somebody else will continue working on that. I really do not
understand what's going on.

-- 
andreas




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