Boost C++ Libraries: Ticket #9630: Program Options: canonical option name incorrect when hyphenated https://svn.boost.org/trac10/ticket/9630 <p> When using a long option name like "external-device", if there is a problem, the name of the option in the error message is printed as "--device" instead of "--external-device". This is due to the implementation in error_with_option_name::get_canonical_option_name() in the value_semantic.cpp file. It calls strip_prefixes() when assigning the value to original_token. But strip_prefixes() simply uses find_last_of("-/"), which finds the dash within the option name and incorrectly uses the following character as the start of the option name. </p> <p> I don't know the proper fix to apply in order to not cause errors in other uses of these functions. </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/9630 Trac 1.4.3 Daniel Hams <daniel.hams@…> Wed, 08 Oct 2014 14:47:38 GMT <link>https://svn.boost.org/trac10/ticket/9630#comment:1 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/9630#comment:1</guid> <description> <p> Looks like this may have been fixed by </p> <p> <a class="ext-link" href="https://svn.boost.org/trac/boost/changeset/82805"><span class="icon">​</span>https://svn.boost.org/trac/boost/changeset/82805</a> </p> <p> and see ticket </p> <p> <a class="ext-link" href="https://svn.boost.org/trac/boost/ticket/8009"><span class="icon">​</span>https://svn.boost.org/trac/boost/ticket/8009</a> </p> <p> (I was having the same error with 1.54 and came to look up if/when it was fixed, found this ticket in addition to the other one). </p> <p> Maybe you could close it if it works for you now? </p> </description> <category>Ticket</category> </item> <item> <author>Tad Ashlock <tad.ashlock@…></author> <pubDate>Sun, 09 Nov 2014 11:18:42 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/9630#comment:2 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/9630#comment:2</guid> <description> <p> I agree that the problem has been fixed, but I am (apparently) not authorized to close the ticket. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Vladimir Prus</dc:creator> <pubDate>Sun, 09 Nov 2014 13:54:04 GMT</pubDate> <title>status changed; resolution set https://svn.boost.org/trac10/ticket/9630#comment:3 https://svn.boost.org/trac10/ticket/9630#comment:3 <ul> <li><strong>status</strong> <span class="trac-field-old">new</span> → <span class="trac-field-new">closed</span> </li> <li><strong>resolution</strong> → <span class="trac-field-new">fixed</span> </li> </ul> Ticket