CanadaHonk / porffor

A from-scratch experimental AOT JS engine, written in JS
https://porffor.dev
MIT License
2.26k stars 55 forks source link

"Math.random(); Porffor.randomByte();" fails #187

Open Rob23oba opened 1 month ago

Rob23oba commented 1 month ago

If you try to run porf -e "Math.random(); Porffor.randomByte();", you get the error message: CompileError: WebAssembly.Module(): Compiling function #1 failed: Invalid global index: 2 @+86

Rob23oba commented 1 month ago

Also, porf -e "console.count" (or countReset / time / timeLog / timeEnd) crashes with TypeError: Cannot read properties of undefined (reading 'ind') in assemble.js where it generates the data section