-
Notifications
You must be signed in to change notification settings - Fork 3.4k
Closed
Description
I'm opening a different bug, even if it was related to #9810 and mentioned in #9562.
The following code does not run properly using 1.39.3:
#include <stdio.h>
long long testAdd(int a, int b)
{
return a+b;
}
typedef long long (*testAddHandler)(int, int);
int main()
{
testAddHandler h = &testAdd;
long long r = h(42, 42);
printf("Result: %d\n", r);
}Built with emcc myfile.cpp -s MAIN_MODULE=1.
And fails with the following:
exception thrown: RuntimeError: indirect call signature mismatch,@http://localhost:8000/index.wasm:wasm-function[176]:0x8988
@http://localhost:8000/index.wasm:wasm-function[177]:0x89d4
Module._main@http://localhost:8000/index.js:41584:32
callMain@http://localhost:8000/index.js:52555:15
doRun@http://localhost:8000/index.js:52614:23
run/<@http://localhost:8000/index.js:52625:7
Metadata
Metadata
Assignees
Labels
No labels