diff options
author | Yury Delendik <ydelendik@mozilla.com> | 2016-05-26 19:43:28 -0500 |
---|---|---|
committer | Yury Delendik <ydelendik@mozilla.com> | 2016-05-26 19:43:28 -0500 |
commit | 0ffa458ed98c71b8106ff659c3335d0408e1fe28 (patch) | |
tree | 6786ce4db4c21ef478a8edc415af29f94053b6c1 /src/compiler-support.h | |
parent | 45618ddc8eee4f288a2d11d1afe763dbdeab8559 (diff) | |
parent | 1963afd6894c1f408b65a0f893e009b4e9f36e55 (diff) | |
download | binaryen-0ffa458ed98c71b8106ff659c3335d0408e1fe28.tar.gz binaryen-0ffa458ed98c71b8106ff659c3335d0408e1fe28.tar.bz2 binaryen-0ffa458ed98c71b8106ff659c3335d0408e1fe28.zip |
Merge pull request #544 from yurydelendik/parse-debug
Allows parsing debug information in the .S files
Diffstat (limited to 'src/compiler-support.h')
-rw-r--r-- | src/compiler-support.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/compiler-support.h b/src/compiler-support.h index 9e298b278..bf2885993 100644 --- a/src/compiler-support.h +++ b/src/compiler-support.h @@ -36,4 +36,10 @@ # define WASM_UNREACHABLE() abort() #endif +// The code might contain TODOs or stubs that read some values but do nothing +// with them. The compiler might fail with [-Werror,-Wunused-variable]. +// The WASM_UNUSED(varible) is a wrapper that helps to suppress the error. +#define WASM_UNUSED(expr) \ + do { if (sizeof expr) { (void)0; } } while (0) + #endif // wasm_compiler_support_h |