summaryrefslogtreecommitdiff
path: root/src/binaryen-c.h
diff options
context:
space:
mode:
authorIrmen de Jong <irmen@razorvine.net>2019-10-21 22:00:10 +0200
committerAlon Zakai <azakai@google.com>2019-10-21 13:00:10 -0700
commit87d12c2dc788e49f82e3bc91b825a40b8d1c2efc (patch)
tree3bd91fb4bce2dc8119fc8445b63c40538bd6c028 /src/binaryen-c.h
parentd2550891e41ad0215b1cae46fa711bc1e264166a (diff)
downloadbinaryen-87d12c2dc788e49f82e3bc91b825a40b8d1c2efc.tar.gz
binaryen-87d12c2dc788e49f82e3bc91b825a40b8d1c2efc.tar.bz2
binaryen-87d12c2dc788e49f82e3bc91b825a40b8d1c2efc.zip
Move WASM_DEPRECATED so that binaryen-c.h is selfcontained. Fixes #2054 (#2399)
Diffstat (limited to 'src/binaryen-c.h')
-rw-r--r--src/binaryen-c.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/binaryen-c.h b/src/binaryen-c.h
index ae0a06835..1015c65de 100644
--- a/src/binaryen-c.h
+++ b/src/binaryen-c.h
@@ -47,7 +47,13 @@
#include <stddef.h>
#include <stdint.h>
-#include "compiler-support.h"
+#ifdef __GNUC__
+#define WASM_DEPRECATED __attribute__((deprecated))
+#elif defined(_MSC_VER)
+#define WASM_DEPRECATED __declspec(deprecated)
+#else
+#define WASM_DEPRECATED
+#endif
#if defined(_MSC_VER) && !defined(BUILD_STATIC_LIBRARY)
#define BINARYEN_API __declspec(dllexport)