@@ -453,6 +453,7 @@ struct NullInstrParserCtx {
453453 Result<> makeTableCopy (Index, TableIdxT*, TableIdxT*) { return Ok{}; }
454454 Result<> makeThrow (Index, TagIdxT) { return Ok{}; }
455455 Result<> makeRethrow (Index, LabelIdxT) { return Ok{}; }
456+ Result<> makeThrowRef (Index) { return Ok{}; }
456457 Result<> makeTupleMake (Index, uint32_t ) { return Ok{}; }
457458 Result<> makeTupleExtract (Index, uint32_t , uint32_t ) { return Ok{}; }
458459 Result<> makeTupleDrop (Index, uint32_t ) { return Ok{}; }
@@ -1406,7 +1407,9 @@ struct ParseDefsCtx : TypeParserCtx<ParseDefsCtx> {
14061407 irBuilder.makeTry (label ? *label : Name{}, type.getSignature ().results ));
14071408 }
14081409
1409- Result<> makeTryTable (Index pos, std::optional<Name> label, HeapType type,
1410+ Result<> makeTryTable (Index pos,
1411+ std::optional<Name> label,
1412+ HeapType type,
14101413 const std::vector<CatchInfo>& info) {
14111414 std::vector<Name> tags;
14121415 std::vector<Index> labels;
@@ -1416,10 +1419,12 @@ struct ParseDefsCtx : TypeParserCtx<ParseDefsCtx> {
14161419 labels.push_back (info.label );
14171420 isRefs.push_back (info.isRef );
14181421 }
1419- return withLoc (
1420- pos,
1421- irBuilder.makeTryTable (label ? *label : Name{}, type.getSignature ().results ,
1422- tags, labels, isRefs));
1422+ return withLoc (pos,
1423+ irBuilder.makeTryTable (label ? *label : Name{},
1424+ type.getSignature ().results ,
1425+ tags,
1426+ labels,
1427+ isRefs));
14231428 }
14241429
14251430 Result<> visitCatch (Index pos, Name tag) {
@@ -1717,6 +1722,10 @@ struct ParseDefsCtx : TypeParserCtx<ParseDefsCtx> {
17171722 return withLoc (pos, irBuilder.makeRethrow (label));
17181723 }
17191724
1725+ Result<> makeThrowRef (Index pos) {
1726+ return withLoc (pos, irBuilder.makeThrowRef ());
1727+ }
1728+
17201729 Result<> makeTupleMake (Index pos, uint32_t arity) {
17211730 return withLoc (pos, irBuilder.makeTupleMake (arity));
17221731 }
0 commit comments