From: Ævar Arnfjörð Bjarmason Date: Fri, 26 Mar 2010 22:19:06 +0000 (+0000) Subject: Add aTHX_ as the first argument to functions that take pTHX_. Now compiles w/threads X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=refs%2Fheads%2Fxs_attrs;p=gitmo%2FClass-MOP.git Add aTHX_ as the first argument to functions that take pTHX_. Now compiles w/threads --- diff --git a/cmop/mop_attr.c b/cmop/mop_attr.c index e82b371..e4ae3fa 100644 --- a/cmop/mop_attr.c +++ b/cmop/mop_attr.c @@ -302,12 +302,12 @@ mop_attr_destroy (mop_attr_t *attr) mop_attr_t *_attr_build_c_instance(SV *perl_attr) { mop_attr_t *attr = mop_attr_new_from_perl_attr(perl_attr); - mop_stash_in_mg(SvRV(perl_attr), NULL, (void *)attr, mop_attr_destroy); + mop_stash_in_mg(aTHX_ SvRV(perl_attr), NULL, (void *)attr, mop_attr_destroy); return attr; } mop_attr_t *mop_attr_get_c_instance (SV *perl_attr) { - mop_attr_t *attr = mop_get_stashed_ptr_in_mg(SvRV(perl_attr)); + mop_attr_t *attr = mop_get_stashed_ptr_in_mg(aTHX_ SvRV(perl_attr)); if ( attr ) return attr; diff --git a/cmop/mop_instance.c b/cmop/mop_instance.c index ed405b5..858ab9e 100644 --- a/cmop/mop_instance.c +++ b/cmop/mop_instance.c @@ -100,12 +100,12 @@ mop_instance_destroy (mop_instance_t *instance) mop_instance_t *_instance_build_c_instance(SV *perl_instance) { mop_instance_t *instance = mop_instance_new_from_perl_instance(perl_instance); - mop_stash_in_mg(SvRV(perl_instance), NULL, (void *)instance, mop_instance_destroy); + mop_stash_in_mg(aTHX_ SvRV(perl_instance), NULL, (void *)instance, mop_instance_destroy); return instance; } mop_instance_t *mop_instance_get_c_instance (SV *perl_instance) { - mop_instance_t *instance = mop_get_stashed_ptr_in_mg(SvRV(perl_instance)); + mop_instance_t *instance = mop_get_stashed_ptr_in_mg(aTHX_ SvRV(perl_instance)); if ( instance ) return instance;