Not sure if this is the right solution as the linkage evolves further but currently there is no way to share tables between JavaScript and WebAssembly when using llvm/clang with webassembly/lld, thus dealing with function pointers in JavaScript is non-trivial.
Quick fix would be to allow importing the same way as memory is currently done, e.g add a --import-table option.
Not sure if this is the right solution as the linkage evolves further but currently there is no way to share tables between JavaScript and WebAssembly when using llvm/clang with webassembly/lld, thus dealing with function pointers in JavaScript is non-trivial.
Quick fix would be to allow importing the same way as memory is currently done, e.g add a
--import-table
option.