summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCheng Shao <astrohavoc@gmail.com>2022-10-21 14:02:07 +0000
committerMarge Bot <ben+marge-bot@smart-cactus.org>2022-11-11 00:26:55 -0500
commitd72466a9fdb2e65196b5d243495cadd68bb07aa2 (patch)
tree646cf87a48f788489a4646561f1db2eed44dbafe
parent00124d12d3ab21951104b279dbc6999b8ea42fba (diff)
downloadhaskell-d72466a9fdb2e65196b5d243495cadd68bb07aa2.tar.gz
rts: prefer ffi_type_void over FFI_TYPE_VOID
This patch uses ffi_type_void instead of FFI_TYPE_VOID in the interpreter code, since the FFI_TYPE_* macros are not available in libffi-wasm32 yet. The libffi public documentation also only mentions the lower-case ffi_type_* symbols, so we should prefer the lower-case API here.
-rw-r--r--rts/Interpreter.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/rts/Interpreter.c b/rts/Interpreter.c
index 581238c36a..00aced17f9 100644
--- a/rts/Interpreter.c
+++ b/rts/Interpreter.c
@@ -1913,7 +1913,7 @@ run_BCO:
void *argptrs[nargs];
void (*fn)(void);
- if (cif->rtype->type == FFI_TYPE_VOID) {
+ if (cif->rtype == &ffi_type_void) {
// necessary because cif->rtype->size == 1 for void,
// but the bytecode generator has not pushed a
// placeholder in this case.