Rename variable, add to example
This commit is contained in:
parent
43ce03fdbd
commit
aaa5e790b6
@ -1636,7 +1636,7 @@ namespace cxxopts
|
||||
const HelpOptionDetails& o,
|
||||
size_t start,
|
||||
size_t allowed,
|
||||
bool m_tab_expansion
|
||||
bool tab_expansion
|
||||
)
|
||||
{
|
||||
auto desc = o.desc;
|
||||
@ -1655,7 +1655,7 @@ namespace cxxopts
|
||||
|
||||
String result;
|
||||
|
||||
if (m_tab_expansion)
|
||||
if (tab_expansion)
|
||||
{
|
||||
String desc2;
|
||||
auto size = size_t{ 0 };
|
||||
|
@ -39,6 +39,8 @@ parse(int argc, const char* argv[])
|
||||
bool apple = false;
|
||||
|
||||
options
|
||||
.set_width(70)
|
||||
.set_tab_expansion()
|
||||
.allow_unrecognised_options()
|
||||
.add_options()
|
||||
("a,apple", "an apple", cxxopts::value<bool>(apple))
|
||||
@ -56,6 +58,7 @@ parse(int argc, const char* argv[])
|
||||
("long-description",
|
||||
"thisisareallylongwordthattakesupthewholelineandcannotbebrokenataspace")
|
||||
("help", "Print help")
|
||||
("tab-expansion", "Tab\texpansion")
|
||||
("int", "An integer", cxxopts::value<int>(), "N")
|
||||
("float", "A floating point number", cxxopts::value<float>())
|
||||
("vector", "A list of doubles", cxxopts::value<std::vector<double>>())
|
||||
|
Loading…
Reference in New Issue
Block a user