From da0fe5d0bdc271bdf0cd48890fbdaf2e9b5d1eea Mon Sep 17 00:00:00 2001 From: Maxime Coste Date: Mon, 5 Sep 2016 23:34:03 +0100 Subject: [PATCH] Small code tweak in generate_switches_doc --- src/parameters_parser.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/parameters_parser.cc b/src/parameters_parser.cc index 8ea0fc81..1633aa6b 100644 --- a/src/parameters_parser.cc +++ b/src/parameters_parser.cc @@ -7,7 +7,9 @@ String generate_switches_doc(const SwitchMap& switches) { String res; for (auto& sw : switches) - res += " -" + sw.key + (sw.value.takes_arg ? " : " : ": ") + sw.value.description + "\n"; + res += format(" -{} {}: {}\n", sw.key, + sw.value.takes_arg ? "" : "", + sw.value.description); return res; }