Skip to content

Code generation without depending on gotos #29

@swang206

Description

@swang206

It is very unfortunate world of warcraft uses Lua 5.1 which does not provide goto.

Although bit is provided, it does not provide all the functions that bitops provide which means they have to be emulated with lua apis itself.

BTW, how can I deal with wasi syscalls? should I implement those syscalls by myself?

    function __FUNCS__.func_3(reg0, reg1, reg2, reg3)
        local reg4;
        reg4 = __IMPORTS__.wasi_snapshot_preview1.fd_write(reg0,reg1,reg2,reg3);
        do return (bit_band(reg4,65535)); end;
    end
    function __FUNCS__.func_4(reg0)
        __IMPORTS__.wasi_snapshot_preview1.proc_exit(reg0);
        error('unreachable');
    end

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions