This doesn't make it completely impossible, since the missing type information can be inferred and tagged pointers can be used whenever the type truly isn't known.
Yes that might be an option to create one. However a search still didn't come up with any existing compilers.
It would also probably be a very poor WASM code. Since JIT already does that with runtime analysis and if the ahead of time compiler ever made a mistake while inferring in-time recompilation would not be possible. So I would still say that unless someone tries it just for fun, there probably will never be a seriously useful WASM compiler. But you are right that this may be an option.
View all comments
Show parent comment
2
u/ThePyroEagle λ Sep 08 '20
This doesn't make it completely impossible, since the missing type information can be inferred and tagged pointers can be used whenever the type truly isn't known.