diff options
author | Nicholas Wilson <nicholas@nicholaswilson.me.uk> | 2018-03-02 14:54:34 +0000 |
---|---|---|
committer | Nicholas Wilson <nicholas@nicholaswilson.me.uk> | 2018-03-02 14:54:34 +0000 |
commit | 36f14f41e6b8f1795cd041a2c9b2f98593cbea8c (patch) | |
tree | a43a69bb2da6f2d428fdb8696e2d986de506e545 /lld/wasm/WriterUtils.cpp | |
parent | c9119b3b6ad65b20c7d2a815d78b86494d3f1095 (diff) | |
download | bcm5719-llvm-36f14f41e6b8f1795cd041a2c9b2f98593cbea8c.tar.gz bcm5719-llvm-36f14f41e6b8f1795cd041a2c9b2f98593cbea8c.zip |
[WebAssembly] Rename global types to match the notation in the spec
llvm-svn: 326583
Diffstat (limited to 'lld/wasm/WriterUtils.cpp')
-rw-r--r-- | lld/wasm/WriterUtils.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/lld/wasm/WriterUtils.cpp b/lld/wasm/WriterUtils.cpp index 88c3757f8c1..e2494b58b68 100644 --- a/lld/wasm/WriterUtils.cpp +++ b/lld/wasm/WriterUtils.cpp @@ -194,8 +194,6 @@ std::string lld::toString(const WasmSignature &Sig) { } std::string lld::toString(const WasmGlobalType &Sig) { - std::string S = toString(static_cast<ValType>(Sig.Type)); - if (Sig.Mutable) - return "mutable " + S; - return S; + return (Sig.Mutable ? "var " : "const ") + + toString(static_cast<ValType>(Sig.Type)); } |