Re: widl: filter_func isn't used when USE_COMPILER_EXCEPTIONS is defined
2009/2/6 Christoph von Wittich <Christoph(a)apiviewer.de>:
diff --git a/tools/widl/proxy.c b/tools/widl/proxy.c index 0dcb737..88c0e53 100644 --- a/tools/widl/proxy.c +++ b/tools/widl/proxy.c @@ -122,10 +122,12 @@ static void init_proxy(const statement_list_t *stmts) print_proxy( " void *This;\n"); print_proxy( "};\n"); print_proxy( "\n"); + print_proxy("#ifndef USE_COMPILER_EXCEPTIONS\n"); print_proxy("static int __proxy_filter( struct __proxy_frame *__frame )\n"); print_proxy( "{\n"); print_proxy( " return (__frame->_StubMsg.dwStubPhase != PROXY_SENDRECEIVE);\n"); print_proxy( "}\n"); + print_proxy("#endif /* USE_COMPILER_EXCEPTIONS */\n"); print_proxy( "\n"); }
I think a better solution to this would be to use proxy_filter as the expression in the RpcExcept statements. Alexandre, what do you think? -- Rob Shearman
Rob Shearman <robertshearman(a)gmail.com> writes:
2009/2/6 Christoph von Wittich <Christoph(a)apiviewer.de>:
diff --git a/tools/widl/proxy.c b/tools/widl/proxy.c index 0dcb737..88c0e53 100644 --- a/tools/widl/proxy.c +++ b/tools/widl/proxy.c @@ -122,10 +122,12 @@ static void init_proxy(const statement_list_t *stmts) print_proxy( " void *This;\n"); print_proxy( "};\n"); print_proxy( "\n"); + print_proxy("#ifndef USE_COMPILER_EXCEPTIONS\n"); print_proxy("static int __proxy_filter( struct __proxy_frame *__frame )\n"); print_proxy( "{\n"); print_proxy( " return (__frame->_StubMsg.dwStubPhase != PROXY_SENDRECEIVE);\n"); print_proxy( "}\n"); + print_proxy("#endif /* USE_COMPILER_EXCEPTIONS */\n"); print_proxy( "\n"); }
I think a better solution to this would be to use proxy_filter as the expression in the RpcExcept statements.
Alexandre, what do you think?
We could do that, though it wouldn't help with the server case. A more generic solution could be to add a dummy reference somewhere in the exception macros to make the compiler believe it's used. I certainly agree we should avoid the extra #ifdefs. -- Alexandre Julliard julliard(a)winehq.org
participants (2)
-
Alexandre Julliard -
Rob Shearman