From: Thomas Geymayer Date: Tue, 5 Mar 2013 17:12:17 +0000 (+0100) Subject: May MSVC likes this more... X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=ff844f67604444763ec9b8d44401fa166f565097;p=simgear.git May MSVC likes this more... --- diff --git a/simgear/nasal/cppbind/detail/functor_templates.hxx b/simgear/nasal/cppbind/detail/functor_templates.hxx index b84ddbfd..03395560 100644 --- a/simgear/nasal/cppbind/detail/functor_templates.hxx +++ b/simgear/nasal/cppbind/detail/functor_templates.hxx @@ -66,19 +66,15 @@ >(name, SG_GHOST_FUNC_TYPE(fn));\ } -#ifdef _MSC_VER -# pragma warning(push) - // C4003: not enough actual parameters for macro - // We really do not want to pass a parameter, even if MSVC can not believe it. -# pragma warning(disable: 4003) -#endif - SG_GHOST_MEM_FN() -#ifdef _MSC_VER -# pragma warning(pop) -#endif +// Work around MSVC warning C4003: not enough actual parameters for macro +// We really do not want to pass a parameter, even if MSVC can not believe it. +#define SG_GHOST_NO_CV + SG_GHOST_MEM_FN(const) + SG_GHOST_MEM_FN(SG_GHOST_NO_CV) #undef SG_GHOST_MEM_FN +#undef SG_GHOST_NO_CV /** * Bind free function accepting an instance of raw_type and an arbitrary