diff options
author | Derek Schuff <dschuff@chromium.org> | 2024-01-17 11:29:19 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-01-17 11:29:19 -0800 |
commit | 103fa3250c46b0c4cf04573c5e075185ca574016 (patch) | |
tree | ba51e90188f44cb15b40047543c31f161aab3c75 /llvm/lib/Target/WebAssembly/AsmParser/WebAssemblyAsmParser.cpp | |
parent | bc90b91885263eb2128315ff636b7f2d200eab48 (diff) | |
download | llvm-103fa3250c46b0c4cf04573c5e075185ca574016.zip llvm-103fa3250c46b0c4cf04573c5e075185ca574016.tar.gz llvm-103fa3250c46b0c4cf04573c5e075185ca574016.tar.bz2 |
[WebAssembly] Use ValType instead of integer types to model wasm tables (#78012)
LLVM models some features found in the binary format with raw integers
and others with nested or enumerated types. This PR switches modeling of
tables and segments to use wasm::ValType rather than uint32_t. This NFC
change is in preparation for modeling more reference types, but IMO is
also cleaner and closer to the spec.
Diffstat (limited to 'llvm/lib/Target/WebAssembly/AsmParser/WebAssemblyAsmParser.cpp')
-rw-r--r-- | llvm/lib/Target/WebAssembly/AsmParser/WebAssemblyAsmParser.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Target/WebAssembly/AsmParser/WebAssemblyAsmParser.cpp b/llvm/lib/Target/WebAssembly/AsmParser/WebAssemblyAsmParser.cpp index 1b92997..3cc4d50 100644 --- a/llvm/lib/Target/WebAssembly/AsmParser/WebAssemblyAsmParser.cpp +++ b/llvm/lib/Target/WebAssembly/AsmParser/WebAssemblyAsmParser.cpp @@ -851,7 +851,7 @@ public: // symbol auto WasmSym = cast<MCSymbolWasm>(Ctx.getOrCreateSymbol(SymName)); WasmSym->setType(wasm::WASM_SYMBOL_TYPE_TABLE); - wasm::WasmTableType Type = {uint8_t(*ElemType), Limits}; + wasm::WasmTableType Type = {*ElemType, Limits}; WasmSym->setTableType(Type); TOut.emitTableType(WasmSym); return expect(AsmToken::EndOfStatement, "EOL"); |