On Fri, 12 Aug 2011, Steffen Mueller wrote: > > Make XSUBs static by default > > At the same time, do not include "STATIC" in XSPROTO and > get rid of the XSPROTO_INTERNAL and XSPROTO_EXTERNAL macros > because of that. This allows Devel::PPPort to continue doing > its evil typedef'ing magic using XSPROTO. It is not "evil" typedef'in magic. XSPROTO() explicitly has been introduced because XS() cannot be used in typedefs: commit 081304cacec6bce6f35c552d790a2bd93a6cda31 Author: Abhijit Menon-Sen <ams@wiw.org> Date: Fri Aug 10 05:42:26 2007 +0000 SWIG uses XS() like this (in the perlrun.swg template): typedef XS(SwigPerlWrapper); typedef SwigPerlWrapper *SwigPerlWrapperPtr; This breaks if XS() includes the 'extern "C"' decoration under C++. The appended patch provides an XSPROTO() macro that could be used by SWIG instead. (Patch from Jan Dubois to fix breakage caused by #28734.) p4raw-id: //depot/perl@31697 So obviously XSPROTO should *not* include "static" either. Cheers, -JanThread Next