From: Florian Ragwitz Date: Tue, 5 Jan 2010 16:16:29 +0000 (+0100) Subject: Be portable across perls with different MGVTBL definitions. X-Git-Tag: 0.93_03~2 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=9a1df90a1e04c3352b212c89633e8c7a50be9f3d;p=gitmo%2FMoose.git Be portable across perls with different MGVTBL definitions. --- diff --git a/Moose.xs b/Moose.xs index 8fbfd53..874e9e0 100644 --- a/Moose.xs +++ b/Moose.xs @@ -3,6 +3,18 @@ #include "XSUB.h" #include "ppport.h" +#ifndef MGf_COPY +# define MGf_COPY 0 +#endif + +#ifndef MGf_DUP +# define MGf_DUP 0 +#endif + +#ifndef MGf_LOCAL +# define MGf_LOCAL 0 +#endif + STATIC int unset_export_flag (pTHX_ SV *sv, MAGIC *mg); STATIC MGVTBL export_flag_vtbl = { @@ -11,9 +23,15 @@ STATIC MGVTBL export_flag_vtbl = { NULL, /* len */ NULL, /* clear */ NULL, /* free */ +#if MGf_COPY NULL, /* copy */ +#endif +#if MGf_DUP NULL, /* dup */ +#endif +#if MGf_LOCAL NULL, /* local */ +#endif }; STATIC bool