onyx-lang / onyx

✨ The compiler and developer toolchain for Onyx

Home Page:https://onyxlang.io

Repository from Github https://github.comonyx-lang/onyxRepository from Github https://github.comonyx-lang/onyx

Mishandled `any` generation

brendanfh opened this issue · comments

The following code type checks, but fails to generate the correct WASM instructions.

main :: () {
    x: any = "test"
    printf("x is {}\n", x)
}

This is because any matches any type, but the code generator fails to handle the case where a separate stack allocation for the any data needs to be made.