From: Matt S Trout Date: Wed, 4 Jun 2008 10:56:51 +0000 (+0000) Subject: assloads of changes, apparently my previous commits failed X-Git-Tag: 0.005000~103 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=9673d7ca1ec235aab1cb6beea90e02166bb9b322;p=p5sagit%2FDevel-Declare.git assloads of changes, apparently my previous commits failed --- diff --git a/Changes b/Changes index 6df7ec1..f1f490d 100644 --- a/Changes +++ b/Changes @@ -1,5 +1,9 @@ Changes for Devel-Declare +0.001010 + - fix traits code, again, so it compiles on 5.10. + +0.001009 - only mangle evals if o->op_ppaddr is actually PL_ppaddr[OP_ENTERVAL] - don't set OPf_SPECIAL on entereval ops, mistaken cargo cult from autobox - fix traits code to work on older 5.8.x perls diff --git a/Declare.xs b/Declare.xs index 1fa8897..1cd3434 100644 --- a/Declare.xs +++ b/Declare.xs @@ -8,7 +8,14 @@ #include #include +#ifndef Newx +# define Newx(v,n,t) New(0,v,n,t) +#endif /* !Newx */ + +#if 1 #define DD_HAS_TRAITS +#endif + #if 0 #define DD_DEBUG #endif @@ -178,7 +185,7 @@ STATIC OP *dd_ck_rv2cv(pTHX_ OP *o) { while (*s && *s != '{') ++s; if (*s) { int tlen = s - traitstart; - New(0, found_traits, tlen+1, char); + Newx(found_traits, tlen+1, char); Copy(traitstart, found_traits, tlen, char); found_traits[tlen] = 0; #ifdef DD_DEBUG diff --git a/Makefile.PL b/Makefile.PL index 3d30929..ea6d149 100644 --- a/Makefile.PL +++ b/Makefile.PL @@ -3,7 +3,6 @@ use inc::Module::Install 0.67; use 5.008001; name 'Devel-Declare'; -version '0.001008'; all_from 'lib/Devel/Declare.pm'; requires 'Scalar::Util'; diff --git a/lib/Devel/Declare.pm b/lib/Devel/Declare.pm index cbba554..3edd596 100644 --- a/lib/Devel/Declare.pm +++ b/lib/Devel/Declare.pm @@ -4,7 +4,7 @@ use strict; use warnings; use 5.008001; -our $VERSION = '0.001008'; +our $VERSION = '0.001010'; # mirrored in Declare.xs as DD_HANDLE_*