-
Notifications
You must be signed in to change notification settings - Fork 560
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
calling closure prototype SEGVs #9830
Comments
From zefram@fysh.orgCreated by zefram@fysh.org$ perl -lwe 'sub MODIFY_CODE_ATTRIBUTES { $proto = $_[1]; return (); } sub foo { my $x = $_[0]; return sub :a0 { $x } } print $proto->()' Callers to foo() will be returned a clone of the "sub :a0 { $x }" code, So I've used the attribute mechanism as a backdoor to get a reference Attempting to call the prototype code from inside the attribute handler Perl Info
|
From @nwc10Thanks for the bug report and analysis On Sat, Aug 15, 2009 at 04:40:16PM -0700, Zefram wrote:
The crash happens at this point in pp_entersub: if (hasargs) { if (items > AvMAX(av) + 1) { av is &PL_sv_undef, so AvMAX() is not a valid macro to apply to it. I'm not sure if this is the right place to detect the problem. In particular, I'm hoping that someone else has a better understanding of this, and can Nicholas Clark |
The RT System itself - Status changed from 'new' to 'open' |
From @cpansproutOn Sun Aug 16 04:06:42 2009, nicholas wrote:
How about this? http://perl5.git.perl.org/perl.git/commitdiff/541ed3a9 |
@cpansprout - Status changed from 'open' to 'resolved' |
From @rgarciaOn 30 November 2010 06:54, Father Chrysostomos via RT
Looks fine; I see you removed already the code for which I did not |
From zefram@fysh.orgFather Chrysostomos via RT wrote:
Looks fine, except a nit in one of the tests: like $@, qr/^Closure prototype called/, @_ will be interpolated there. Have another backslash. -zefram |
Migrated from rt.perl.org#68560 (status was 'resolved')
Searchable as RT68560$
The text was updated successfully, but these errors were encountered: