remove --undefok
I think we originally added this for the bots, back in the good old days
when the bot scripts weren't versioned with Skia. No bots use this now.
Change-Id: Icdee95d27fb928d0215601e082d056e611eb6202
Reviewed-on: https://skia-review.googlesource.com/c/181980
Reviewed-by: Ben Wagner <benjaminwagner@google.com>
Commit-Queue: Ben Wagner <benjaminwagner@google.com>
diff --git a/bench/nanobench.cpp b/bench/nanobench.cpp
index 35fcefa..d9f24e5 100644
--- a/bench/nanobench.cpp
+++ b/bench/nanobench.cpp
@@ -102,8 +102,6 @@
return str;
}
-DECLARE_bool(undefok);
-
DEFINE_int32(loops, kDefaultLoops, loops_help_txt().c_str());
DEFINE_int32(samples, 10, "Number of samples to measure for each bench.");
@@ -503,13 +501,10 @@
// If no just default configs were requested, then we're okay.
if (array.count() == 0 || FLAGS_config.count() == 0 ||
- // If we've been told to ignore undefined flags, we're okay.
- FLAGS_undefok ||
// Otherwise, make sure that all specified configs have been created.
array.count() == configs->count()) {
return;
}
- SkDebugf("Invalid --config. Use --undefok to bypass this warning.\n");
exit(1);
}
diff --git a/dm/DM.cpp b/dm/DM.cpp
index 6f63b36..10f239b 100644
--- a/dm/DM.cpp
+++ b/dm/DM.cpp
@@ -63,7 +63,6 @@
extern bool gSkForceRasterPipelineBlitter;
-DECLARE_bool(undefok);
DEFINE_string(src, "tests gm skp image", "Source types to test.");
DEFINE_bool(nameByHash, false,
"If true, write to FLAGS_writePath[0]/<hash>.png instead of "
@@ -1016,13 +1015,10 @@
if (configs.count() == 0 ||
// If we're using the default configs, we're okay.
defaultConfigs ||
- // If we've been told to ignore undefined flags, we're okay.
- FLAGS_undefok ||
// Otherwise, make sure that all specified configs have become sinks.
configs.count() == gSinks.count()) {
return true;
}
- info("Invalid --config. Use --undefok to bypass this warning.\n");
return false;
}
diff --git a/tools/flags/SkCommandLineFlags.cpp b/tools/flags/SkCommandLineFlags.cpp
index 62625e1..5be6d85 100644
--- a/tools/flags/SkCommandLineFlags.cpp
+++ b/tools/flags/SkCommandLineFlags.cpp
@@ -11,8 +11,6 @@
#include <stdlib.h>
-DEFINE_bool(undefok, false, "Silently ignore unknown flags instead of crashing.");
-
template <typename T> static void ignore_result(const T&) {}
bool SkFlagInfo::CreateStringFlag(const char* name, const char* shortName,
@@ -349,12 +347,8 @@
i++; // skip YES
} else
#endif
- if (FLAGS_undefok) {
- SkDebugf("FYI: ignoring unknown flag '%s'.\n", argv[i]);
- } else {
- SkDebugf("Got unknown flag '%s'. Exiting.\n", argv[i]);
- exit(-1);
- }
+ SkDebugf("Got unknown flag '%s'. Exiting.\n", argv[i]);
+ exit(-1);
}
}
}