diff options
Diffstat (limited to 'src/passes/GlobalRefining.cpp')
-rw-r--r-- | src/passes/GlobalRefining.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/passes/GlobalRefining.cpp b/src/passes/GlobalRefining.cpp index 626fbaeb5..f3bea3d3d 100644 --- a/src/passes/GlobalRefining.cpp +++ b/src/passes/GlobalRefining.cpp @@ -34,7 +34,7 @@ struct GlobalRefining : public Pass { // Only modifies globals and global.get operations. bool requiresNonNullableLocalFixups() override { return false; } - void run(PassRunner* runner, Module* module) override { + void run(Module* module) override { if (!module->features.hasGC()) { return; } @@ -114,7 +114,9 @@ struct GlobalRefining : public Pass { GetUpdater(GlobalRefining& parent, Module& wasm) : parent(parent), wasm(wasm) {} - GetUpdater* create() override { return new GetUpdater(parent, wasm); } + std::unique_ptr<Pass> create() override { + return std::make_unique<GetUpdater>(parent, wasm); + } // If we modify anything in a function then we must refinalize so that // types propagate outwards. @@ -135,7 +137,7 @@ struct GlobalRefining : public Pass { } } }; - GetUpdater(*this, *module).run(runner, module); + GetUpdater(*this, *module).run(getPassRunner(), module); } }; |