diff options
author | Chun-wei Fan <fanchunwei@src.gnome.org> | 2015-06-05 17:38:26 -0700 |
---|---|---|
committer | Eric Anholt <eric@anholt.net> | 2015-06-05 17:51:08 -0700 |
commit | 7d5e8e9d5604736601e28f4c8530759fc537fd12 (patch) | |
tree | 336fdd236f8b191935bd8dd6233c9805cfeed2c6 /src/dispatch_common.h | |
parent | e2424977284e7f0f124b2ae84d48addbfbf4b03e (diff) | |
download | libepoxy-7d5e8e9d5604736601e28f4c8530759fc537fd12.tar.gz |
Put the callspec after the return type for MSVC.
Visual Studio does not like __stdcall before the return type, which is
what GLAPIENTRY and EPOXY_CALLSPEC expands to on Windows.
Diffstat (limited to 'src/dispatch_common.h')
-rw-r--r-- | src/dispatch_common.h | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/dispatch_common.h b/src/dispatch_common.h index 6b8503a..eea4e8f 100644 --- a/src/dispatch_common.h +++ b/src/dispatch_common.h @@ -77,11 +77,11 @@ #endif #define UNWRAPPED_PROTO(x) (GLAPIENTRY *x) -#define WRAPPER_VISIBILITY static GLAPIENTRY +#define WRAPPER_VISIBILITY(type) static type GLAPIENTRY #define WRAPPER(x) x ## _wrapped #define GEN_GLOBAL_REWRITE_PTR(name, args, passthrough) \ - static EPOXY_CALLSPEC void \ + static void EPOXY_CALLSPEC \ name##_global_rewrite_ptr args \ { \ name = (void *)name##_resolver(); \ @@ -89,7 +89,7 @@ } #define GEN_GLOBAL_REWRITE_PTR_RET(ret, name, args, passthrough) \ - static EPOXY_CALLSPEC ret \ + static ret EPOXY_CALLSPEC \ name##_global_rewrite_ptr args \ { \ name = (void *)name##_resolver(); \ @@ -98,7 +98,7 @@ #if USING_DISPATCH_TABLE #define GEN_DISPATCH_TABLE_REWRITE_PTR(name, args, passthrough) \ - static EPOXY_CALLSPEC void \ + static void EPOXY_CALLSPEC \ name##_dispatch_table_rewrite_ptr args \ { \ struct dispatch_table *dispatch_table = get_dispatch_table(); \ @@ -108,7 +108,7 @@ } #define GEN_DISPATCH_TABLE_REWRITE_PTR_RET(ret, name, args, passthrough) \ - static EPOXY_CALLSPEC ret \ + static ret EPOXY_CALLSPEC \ name##_dispatch_table_rewrite_ptr args \ { \ struct dispatch_table *dispatch_table = get_dispatch_table(); \ @@ -118,14 +118,14 @@ } #define GEN_DISPATCH_TABLE_THUNK(name, args, passthrough) \ - static EPOXY_CALLSPEC void \ + static void EPOXY_CALLSPEC \ name##_dispatch_table_thunk args \ { \ get_dispatch_table()->name passthrough; \ } #define GEN_DISPATCH_TABLE_THUNK_RET(ret, name, args, passthrough) \ - static EPOXY_CALLSPEC ret \ + static ret EPOXY_CALLSPEC \ name##_dispatch_table_thunk args \ { \ return get_dispatch_table()->name passthrough; \ |