From c74acc0baece1296ad58a0ff44119fb36d98d2c6 Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Mon, 25 Jan 2021 18:12:37 +0000 Subject: Debug info handling for new EH try-catch (#3496) We now have multiple catches in each try, and a possible catch-all. This changes our "extra delimiter" storage to store either an "else" (unchanged from before) or an arbitrary list of things - we use that for catches. --- src/wasm/wasm-debug.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'src/wasm/wasm-debug.cpp') diff --git a/src/wasm/wasm-debug.cpp b/src/wasm/wasm-debug.cpp index 52baaf24d..2c5ed9515 100644 --- a/src/wasm/wasm-debug.cpp +++ b/src/wasm/wasm-debug.cpp @@ -361,7 +361,7 @@ struct AddrExprMap { // bloat the common case which is represented in the earlier maps. struct DelimiterInfo { Expression* expr; - BinaryLocations::DelimiterId id; + size_t id; }; std::unordered_map delimiterMap; @@ -414,8 +414,7 @@ private: for (Index i = 0; i < delimiter.size(); i++) { if (delimiter[i] != 0) { assert(delimiterMap.count(delimiter[i]) == 0); - delimiterMap[delimiter[i]] = - DelimiterInfo{expr, BinaryLocations::DelimiterId(i)}; + delimiterMap[delimiter[i]] = DelimiterInfo{expr, i}; } } } -- cgit v1.2.3