From 0f147b997e37fe0db1b36ee7078390d19d86ff8f Mon Sep 17 00:00:00 2001 From: Marcelo Matus Date: Thu, 9 Feb 2006 20:42:34 +0000 Subject: [PATCH] delete extra spaces git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@8762 626c5289-ae23-0410-ae9c-e8d60b6d4f22 --- Lib/typemaps/exception.swg | 6 +++--- Lib/typemaps/strings.swg | 2 +- Lib/typemaps/swigmacros.swg | 10 ++++------ 3 files changed, 8 insertions(+), 10 deletions(-) diff --git a/Lib/typemaps/exception.swg b/Lib/typemaps/exception.swg index e79564529..86ef72f1b 100644 --- a/Lib/typemaps/exception.swg +++ b/Lib/typemaps/exception.swg @@ -19,10 +19,10 @@ %insert("runtime") { - %define_as(SWIG_exception_fail(code, msg), %block(%error(code, msg); SWIG_fail)) +%define_as(SWIG_exception_fail(code, msg), %block(%error(code, msg); SWIG_fail)) - %define_as(SWIG_contract_assert(expr, msg), - if (!(expr)) { %error(SWIG_RuntimeError, msg); SWIG_fail; } else) +%define_as(SWIG_contract_assert(expr, msg), + if (!(expr)) { %error(SWIG_RuntimeError, msg); SWIG_fail; } else) } diff --git a/Lib/typemaps/strings.swg b/Lib/typemaps/strings.swg index 8664de901..377bf2bd5 100644 --- a/Lib/typemaps/strings.swg +++ b/Lib/typemaps/strings.swg @@ -519,7 +519,7 @@ SWIG_From##CharName##Array(const Char *cptr, size_t size) } %fragment("SWIG_As" #CharName "Ptr","header",fragment=#SWIG_AsCharPtrAndSize) { - %define_as(SWIG_As##CharName##Ptr(obj, val, alloc), SWIG_AsCharPtrAndSize(obj, val, NULL, alloc)) +%define_as(SWIG_As##CharName##Ptr(obj, val, alloc), SWIG_AsCharPtrAndSize(obj, val, NULL, alloc)) } %fragment("SWIG_As" #CharName "Array","header",fragment=#SWIG_AsCharPtrAndSize) { diff --git a/Lib/typemaps/swigmacros.swg b/Lib/typemaps/swigmacros.swg index 9803f79c4..e898a461a 100644 --- a/Lib/typemaps/swigmacros.swg +++ b/Lib/typemaps/swigmacros.swg @@ -98,9 +98,7 @@ #define %block(Block...) %begin_block Block; %end_block /* define a new macro */ -%define %define_as(Def, Val...) -%#define Def Val -%enddef +%define %define_as(Def, Val...)%#define Def Val %enddef /* include C++ or else value */ %define %ifcplusplus(cppval, nocppval) @@ -114,7 +112,7 @@ nocppval /* insert the SWIGVERSION in the interface and the wrapper code */ #if SWIG_VERSION %insert("header") { - %define_as(SWIGVERSION, SWIG_VERSION) +%define_as(SWIGVERSION, SWIG_VERSION) } #endif @@ -148,8 +146,8 @@ nocppval #define %as_voidptrptr(a) SWIG_as_voidptrptr(a) %insert("header") { - %define_as(SWIG_as_voidptr(a), %const_cast(%static_cast(a,const void *), void *)) - %define_as(SWIG_as_voidptrptr(a), ((void)%as_voidptr(*a),%reinterpret_cast(a, void**))) +%define_as(SWIG_as_voidptr(a), %const_cast(%static_cast(a,const void *), void *)) +%define_as(SWIG_as_voidptrptr(a), ((void)%as_voidptr(*a),%reinterpret_cast(a, void**))) }