From aa4bc77bc967fd8911c30d7e69e44a9a0aef553a Mon Sep 17 00:00:00 2001 From: Thomas Lively Date: Tue, 28 Feb 2023 17:19:09 -0600 Subject: [NFC] Internally rename `ArrayInit` to `ArrayNewFixed` (#5526) To match the standard instruction name, rename the expression class without changing any parsing or printing behavior. A follow-on PR will take care of the functional side of this change while keeping support for parsing the old name. This change will allow `ArrayInit` to be used as the expression class for the upcoming `array.init_data` and `array.init_elem` instructions. --- src/wasm/wasm-stack.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/wasm/wasm-stack.cpp') diff --git a/src/wasm/wasm-stack.cpp b/src/wasm/wasm-stack.cpp index 1c12718ce..3f53e3dde 100644 --- a/src/wasm/wasm-stack.cpp +++ b/src/wasm/wasm-stack.cpp @@ -2193,9 +2193,9 @@ void BinaryInstWriter::visitArrayNewSeg(ArrayNewSeg* curr) { o << U32LEB(curr->segment); } -void BinaryInstWriter::visitArrayInit(ArrayInit* curr) { +void BinaryInstWriter::visitArrayNewFixed(ArrayNewFixed* curr) { o << int8_t(BinaryConsts::GCPrefix); - o << U32LEB(BinaryConsts::ArrayInitStatic); + o << U32LEB(BinaryConsts::ArrayNewFixedStatic); parent.writeIndexedHeapType(curr->type.getHeapType()); o << U32LEB(curr->values.size()); } -- cgit v1.2.3