diff options
Diffstat (limited to 'XSUB.h')
-rw-r--r-- | XSUB.h | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -107,7 +107,11 @@ is a lexical $_ in scope. # if defined(HASATTRIBUTE_UNUSED) && !defined(__cplusplus) # define XS(name) void name(pTHX_ CV* cv __attribute__unused__) # else -# define XS(name) void name(pTHX_ CV* cv) +# ifdef __cplusplus +# define XS(name) extern "C" void name(pTHX_ CV* cv) +# else +# define XS(name) void name(pTHX_ CV* cv) +# endif # endif #endif |