diff options
author | Alon Zakai <alonzakai@gmail.com> | 2015-10-29 16:56:54 -0700 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2015-10-29 16:56:54 -0700 |
commit | 9f9e8f848dd3472e4ffa9f1ba301dd261f5e10da (patch) | |
tree | 467742062c82ae631db42302b9dc00962f9864e2 | |
parent | c9cd6c7726df7ee0ca4cb6ecf969d98c50335046 (diff) | |
download | binaryen-9f9e8f848dd3472e4ffa9f1ba301dd261f5e10da.tar.gz binaryen-9f9e8f848dd3472e4ffa9f1ba301dd261f5e10da.tar.bz2 binaryen-9f9e8f848dd3472e4ffa9f1ba301dd261f5e10da.zip |
fix function type printing
-rw-r--r-- | src/wasm.h | 4 | ||||
-rw-r--r-- | test/emcc_hello_world.wast | 6 |
2 files changed, 5 insertions, 5 deletions
diff --git a/src/wasm.h b/src/wasm.h index 87e18c7ba..8869c7e80 100644 --- a/src/wasm.h +++ b/src/wasm.h @@ -392,7 +392,7 @@ public: std::ostream& print(std::ostream &o, unsigned indent, bool full=false) { if (full) { printOpening(o, "type") << ' '; - name.print(o); + name.print(o) << " (func"; } if (params.size() > 0) { o << ' '; @@ -409,7 +409,7 @@ public: printBasicType(o, result) << ')'; } if (full) { - o << ')'; + o << "))";; } return o; } diff --git a/test/emcc_hello_world.wast b/test/emcc_hello_world.wast index ec4769a6d..6e96a9644 100644 --- a/test/emcc_hello_world.wast +++ b/test/emcc_hello_world.wast @@ -1,7 +1,7 @@ (module - (type $FUNCSIG$ii (param i32) (result i32)) - (type $FUNCSIG$iiii (param i32 i32 i32) (result i32)) - (type $FUNCSIG$vi (param i32)) + (type $FUNCSIG$ii (func (param i32) (result i32))) + (type $FUNCSIG$iiii (func (param i32 i32 i32) (result i32))) + (type $FUNCSIG$vi (func (param i32))) (import $Math_clz32 "global" "clz32" (param i32) (result i32)) (import $___lock "env" "___lock" (param i32)) (import $___syscall140 "env" "___syscall140" (param i32 i32) (result i32)) |