diff options
Diffstat (limited to 'src/passes/Precompute.cpp')
-rw-r--r-- | src/passes/Precompute.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/passes/Precompute.cpp b/src/passes/Precompute.cpp index 37686de1a..e06103c11 100644 --- a/src/passes/Precompute.cpp +++ b/src/passes/Precompute.cpp @@ -23,6 +23,7 @@ #include <wasm-builder.h> #include <wasm-interpreter.h> #include <ast_utils.h> +#include "ast/manipulation.h" namespace wasm { @@ -142,6 +143,11 @@ struct Precompute : public WalkerPass<PostWalker<Precompute, UnifiedExpressionVi ExpressionManipulator::nop(curr); } } + + void visitFunction(Function* curr) { + // removing breaks can alter types + ReFinalize().walkFunctionInModule(curr, getModule()); + } }; Pass *createPrecomputePass() { |