summaryrefslogtreecommitdiff
path: root/src/passes/ExtractFunction.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/passes/ExtractFunction.cpp')
-rw-r--r--src/passes/ExtractFunction.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/passes/ExtractFunction.cpp b/src/passes/ExtractFunction.cpp
index 440468ede..df53afbf2 100644
--- a/src/passes/ExtractFunction.cpp
+++ b/src/passes/ExtractFunction.cpp
@@ -62,7 +62,7 @@ struct ExtractFunction : public Pass {
bool addsEffects() override { return true; }
void run(Module* module) override {
- Name name = getPassOptions().getArgument(
+ Name name = getArgument(
"extract-function",
"ExtractFunction usage: wasm-opt --extract-function=FUNCTION_NAME");
extract(getPassRunner(), module, name);
@@ -74,10 +74,9 @@ struct ExtractFunctionIndex : public Pass {
bool addsEffects() override { return true; }
void run(Module* module) override {
- std::string index =
- getPassOptions().getArgument("extract-function-index",
- "ExtractFunctionIndex usage: wasm-opt "
- "--extract-function-index=FUNCTION_INDEX");
+ std::string index = getArgument("extract-function-index",
+ "ExtractFunctionIndex usage: wasm-opt "
+ "--extract-function-index=FUNCTION_INDEX");
for (char c : index) {
if (!std::isdigit(c)) {
Fatal() << "Expected numeric function index";