diff --git a/include/ppx/command_line_parser.h b/include/ppx/command_line_parser.h index 9952c6da8..d71522fc6 100644 --- a/include/ppx/command_line_parser.h +++ b/include/ppx/command_line_parser.h @@ -73,7 +73,7 @@ class CliOptions public: CliOptions() = default; - bool HasExtraOption(std::string_view option) const { return mAllOptions.contains(option); } + bool HasExtraOption(std::string_view option) const; // Returns the number of unique options and flags that were specified on the commandline, // not counting multiple appearances of the same flag such as: --assets-path a --assets-path b diff --git a/src/ppx/command_line_parser.cpp b/src/ppx/command_line_parser.cpp index d5069cc87..c3f717cb2 100644 --- a/src/ppx/command_line_parser.cpp +++ b/src/ppx/command_line_parser.cpp @@ -37,6 +37,11 @@ bool StartsWithDoubleDash(std::string_view s) namespace ppx { +bool CliOptions::HasExtraOption(std::string_view option) const +{ + return mAllOptions.contains(option); +} + std::pair CliOptions::GetOptionValueOrDefault(std::string_view optionName, const std::pair& defaultValue) const { auto it = mAllOptions.find(optionName);