From b37579fad2dc6d95c35825df75d128d3ca4d663c Mon Sep 17 00:00:00 2001 From: gibbed Date: Wed, 8 Apr 2020 12:29:02 -0500 Subject: [PATCH] [Base] Fix path parsing from commandline. --- src/xenia/base/cvar.h | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/src/xenia/base/cvar.h b/src/xenia/base/cvar.h index d68173ddf..564f32ff7 100644 --- a/src/xenia/base/cvar.h +++ b/src/xenia/base/cvar.h @@ -104,16 +104,33 @@ template void CommandVar::AddToLaunchOptions(cxxopts::Options* options) { options->add_options()(name_, description_, cxxopts::value()); } +template <> +inline void CommandVar::AddToLaunchOptions( + cxxopts::Options* options) { + options->add_options()(name_, description_, cxxopts::value()); +} template void ConfigVar::AddToLaunchOptions(cxxopts::Options* options) { options->add_options(category_)(this->name_, this->description_, cxxopts::value()); } +template <> +inline void ConfigVar::AddToLaunchOptions( + cxxopts::Options* options) { + options->add_options(category_)(this->name_, this->description_, + cxxopts::value()); +} template void CommandVar::LoadFromLaunchOptions(cxxopts::ParseResult* result) { T value = (*result)[name_].template as(); SetCommandLineValue(value); } +template <> +inline void CommandVar::LoadFromLaunchOptions( + cxxopts::ParseResult* result) { + std::string value = (*result)[name_].template as(); + SetCommandLineValue(value); +} template void ConfigVar::LoadConfigValue(std::shared_ptr result) { SetConfigValue(*cpptoml::get_impl(result));