nayakgi / perl-compiler

Automatically exported from code.google.com/p/perl-compiler
Other
0 stars 0 forks source link

wrong @- values #281

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
$>perlcc -O3 -r -e '"I like pie" =~ /(I) (like) (pie)/; "@-" eq  "0 0 2 7" and 
print "ok\n"; print "\@- = @-\n\@+ = @+\n"' 
@- = 10 1 6 10
@+ = 10 1 6 10

$>perl -e '"I like pie" =~ /(I) (like) (pie)/; "@-" eq  "0 0 2 7" and print 
"ok\n"; print "\@- = @-\n\@+ = @+\n"'  
ok
@- = 0 0 2 7
@+ = 10 1 6 10

Possibly both globals are being set to the same variable at some point?

Original issue reported on code.google.com by todd.e.rinaldo on 24 Jan 2014 at 12:41

GoogleCodeExporter commented 9 years ago
Still handled in #90 t/issue90.t test 16

Original comment by reini.urban on 24 Jan 2014 at 6:03

GoogleCodeExporter commented 9 years ago
Issue 295 has been merged into this issue.

Original comment by reini.urban on 10 Feb 2014 at 3:47

GoogleCodeExporter commented 9 years ago

Original comment by reini.urban on 10 Feb 2014 at 3:47

GoogleCodeExporter commented 9 years ago

Original comment by reini.urban on 10 Feb 2014 at 3:48

GoogleCodeExporter commented 9 years ago
fails since 5.10 (threaded and non)
fails also in 5.6

added testcases to t/testc.sh 281 295

Original comment by reini.urban on 10 Feb 2014 at 3:51

GoogleCodeExporter commented 9 years ago
new testcase t/issue281.t combining #220, #281, #295

Original comment by reini.urban on 10 Feb 2014 at 4:21

GoogleCodeExporter commented 9 years ago
This is most likely issue that might appear in CPAN code. And should be easiest 
to fix

Original comment by reini.urban on 11 Feb 2014 at 4:23

GoogleCodeExporter commented 9 years ago
While we are here, check this 5.18-blead bug also: 
https://rt.perl.org/Ticket/Display.html?id=121573 Segfault in perl (including 
perl-5.18.2 and bleadperl with PERL_NO_COW) after using @+

bisected to 13b0f67d12a6400f01bbc27945223c 
re-enable Copy-on-Write by default.

Original comment by reini.urban on 3 Apr 2014 at 2:39

GoogleCodeExporter commented 9 years ago
Fixed with commit 3cc04d2b40b695a151098253fe5a6a61eb73a940
Author: Reini Urban <rurban@cpanel.net>
Date:   Fri May 9 13:40:27 2014 -0500

    C: fix @- issue 281

    special-case @- regdata magic (2nd sv_magic arg is NULL).
    Improve @- handling of unnecessary Tie::Hash::NamedCapture later

Original comment by reini.urban on 9 May 2014 at 6:42