From 1218fe3e47a178c2a6a8a4d22b30326dc198bf3e Mon Sep 17 00:00:00 2001 From: stevenfontanella Date: Wed, 25 Feb 2026 19:30:31 +0000 Subject: [PATCH] Fix call indirect 64 spec test --- scripts/test/shared.py | 1 - src/parser/context-decls.cpp | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/scripts/test/shared.py b/scripts/test/shared.py index ad02b617d44..50acdb33cc2 100644 --- a/scripts/test/shared.py +++ b/scripts/test/shared.py @@ -404,7 +404,6 @@ def get_tests(test_dir, extensions=[], recursive=False): SPEC_TESTSUITE_TESTS_TO_SKIP = [ 'array_new_elem.wast', # Failure to parse element segment item abbreviation 'binary.wast', # Missing data count section validation - 'call_indirect64.wast', # Failure to parse element segment abbreviation 'comments.wast', # Issue with carriage returns being treated as newlines 'const.wast', # Hex float constant not recognized as out of range 'conversions.wast', # Promoted NaN should be canonical diff --git a/src/parser/context-decls.cpp b/src/parser/context-decls.cpp index f02ec30dd66..888d6874842 100644 --- a/src/parser/context-decls.cpp +++ b/src/parser/context-decls.cpp @@ -122,7 +122,7 @@ Result<> ParseDeclsCtx::addImplicitElems(TypeT, ElemListT&& elems) { auto& table = *wasm.tables.back(); auto e = std::make_unique(); e->table = table.name; - e->offset = Builder(wasm).makeConstPtr(0, Type::i32); + e->offset = Builder(wasm).makeConstPtr(0, table.addressType); e->name = Names::getValidElementSegmentName(wasm, "implicit-elem"); wasm.addElementSegment(std::move(e));