From 7611711651a7a3f9d5e6117635fce85ff72cca59 Mon Sep 17 00:00:00 2001 From: Baptiste Wicht Date: Fri, 13 Feb 2015 10:55:26 +0100 Subject: [PATCH] Better support for spaces This fixes support for options such as --file="folder with spaces/file". --- src/cxxopts.hpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/cxxopts.hpp b/src/cxxopts.hpp index 993ca68..0d7ae1e 100644 --- a/src/cxxopts.hpp +++ b/src/cxxopts.hpp @@ -410,6 +410,13 @@ namespace cxxopts //so that we can write --long=yes explicitly value = true; } + + inline + void + parse_value(const std::string& text, std::string& value) + { + value = text; + } template struct value_has_arg