Ben Noordhuis d464b25322 support --target-arch wasm32 (#1094)
Add wasm32 support to the build-obj, build-exe and build-lib commands
of the stage 1 compiler.  Wasm64 should work transparently once it's
supported in upstream LLVM.

To export a function:

    // lib.zig - for exposition, not necessary for this example
    pub use @import("add.zig");

    // add.zig
    export fn add(a: i32, b: i32) i32 {
        return a + b;
    }

To import a function:

    // cube.zig
    extern fn square(x: i32) i32;

    export fn cube(x: i32) i32 {
        return x * square(x);
    }
2018-06-09 22:39:22 -04:00
..
2018-04-15 13:26:58 -04:00
2018-04-15 13:26:58 -04:00
2017-12-02 22:32:39 -05:00
2016-09-19 11:54:01 -04:00
2017-11-29 23:09:35 -05:00
2017-11-29 23:09:35 -05:00
2016-12-01 21:08:12 -05:00
2018-06-07 19:50:25 -04:00
2018-06-09 22:39:22 -04:00
2016-02-11 01:33:27 -07:00
2017-04-10 20:02:39 -04:00
2018-04-01 17:03:06 +12:00
2018-05-12 17:35:15 -04:00
2017-10-01 21:05:08 -04:00
2018-06-04 14:09:31 -04:00
2018-04-18 12:16:42 -04:00