Sascha Ochsenknecht
9a04daa2b2
Better detection of missing values on command line, Fixes #3423
...
[SVN r58184]
2009-12-06 09:52:53 +00:00
Sascha Ochsenknecht
5f01f7bf3f
better detection of ambiguous options, see Ticket #3423
...
[SVN r58152]
2009-12-05 08:08:45 +00:00
Sascha Ochsenknecht
6e0f1db1fc
Clean up exception classes, changes regarding to Ticket #3423
...
[SVN r58138]
2009-12-04 13:38:56 +00:00
Sascha Ochsenknecht
35bf26f432
Changed defaults for split_unix() function to be more compliant to unix command line style
...
[SVN r58134]
2009-12-04 10:15:11 +00:00
Sascha Ochsenknecht
00dadb4203
enhance split_unix() to allow unix style splitting of command line string
...
[SVN r58133]
2009-12-04 08:09:43 +00:00
Sascha Ochsenknecht
263534a213
rename description_length to min_description_length for better semantic
...
[SVN r58112]
2009-12-03 11:11:34 +00:00
Sascha Ochsenknecht
60966caa35
Additional parameter to allow user to specify width of column for description text, patch from Chard, Fixes #3703
...
[SVN r58095]
2009-12-02 13:35:54 +00:00
Sascha Ochsenknecht
b3e9b5180e
add general split function, Fixes #2561
...
[SVN r57971]
2009-11-27 17:47:51 +00:00
Sascha Ochsenknecht
63c0bf7bfc
remove compile warnings, Fixes #2562
...
[SVN r57800]
2009-11-20 09:09:36 +00:00
Vladimir Prus
aaa914e9a4
Add option name to a few exception classes.
...
Fixes #3423 . Patch from Sascha Ochsenknecht.
[SVN r57746]
2009-11-18 13:35:14 +00:00
Hartmut Kaiser
79b43138d6
ProgramOptions: Fixed warning about not all control paths returning a value
...
[SVN r53795]
2009-06-11 20:05:19 +00:00
Vladimir Prus
354717d9c9
Make program_options compile with disabled exceptions.
...
It appears the all throw statements are during the
parsing, so alternative error reporting strategies are
possible.
Closes #2096 .
[SVN r53723]
2009-06-07 16:10:03 +00:00
Vladimir Prus
55a1a045a3
Include missing #include of 'iterator'.
...
Addresses #3072 .
[SVN r53623]
2009-06-04 10:09:15 +00:00
Jeremiah Willcock
3c3b8d8818
Fixed most tab and min/max issues from trunk inspection report
...
[SVN r53141]
2009-05-20 19:19:00 +00:00
Vladimir Prus
454c878389
Make sure _MSC_VER is defined before checking its value.
...
[SVN r51639]
2009-03-07 15:32:14 +00:00
Marshall Clow
4dcce9efce
Replaced all occurrences of non-ASCII copyright symbol with '(c)' for people using non-ASCII code pages
...
[SVN r43992]
2008-04-02 01:42:32 +00:00
Vladimir Prus
316e2fabe4
Tolerate argc being zero.
...
Patch from C. K. Jester-Young.
[SVN r43207]
2008-02-10 13:13:41 +00:00
Beman Dawes
152fbd8384
// Add or correct comment identifying Boost library this header is associated with.
...
[SVN r41173]
2007-11-17 20:13:16 +00:00
Vladimir Prus
e51a3ae742
Support for 'implicit' options.
...
Patch from Bryan Green.
Fixes #1131 .
[SVN r38514]
2007-08-08 18:40:48 +00:00
Vladimir Prus
8c39e5aa8d
When parsing vector<T>, use validator for
...
type T.
Fixes #1118 .
[SVN r38459]
2007-08-05 18:38:07 +00:00
Vladimir Prus
d0aa5abee5
Implement support for unregistered options in config files. Closes #687 .
...
[SVN r38191]
2007-07-11 19:39:06 +00:00
Vladimir Prus
c00c4a57db
Define static const member in .cpp. Fixes #646 .
...
[SVN r38108]
2007-06-28 07:05:50 +00:00
Hartmut Kaiser
e42f028278
Fixed VC8 warnings about inconsistent dll export declarations.
...
[SVN r38099]
2007-06-26 19:13:33 +00:00
John Maddock
8c1982de82
Fix for Borland compilers.
...
[SVN r35652]
2006-10-18 12:33:54 +00:00
Hartmut Kaiser
b99ae04040
Fixed a dllimport/dllexport problem.
...
[SVN r34049]
2006-05-20 22:14:41 +00:00
Vladimir Prus
de66d37405
Make positional_options_description::add return reference to *this.
...
[SVN r33989]
2006-05-18 05:59:56 +00:00
Vladimir Prus
a4375600a2
Make validation_error::what public, as it's public in std::exception.
...
[SVN r33969]
2006-05-15 14:05:47 +00:00
Vladimir Prus
bec34dd1b9
Note that variables_map is inherited from std::map, since BoostBook
...
"hides" that information.
[SVN r33786]
2006-04-24 09:50:30 +00:00
Vladimir Prus
7b73b2e84c
Fix typos.
...
Thanks to Olaf van der Spek for the report!
[SVN r33784]
2006-04-24 09:41:22 +00:00
Vladimir Prus
5e4b39d672
Fix SF bug 1395874. When both "all" and "all-chroots" options were registered
...
and "--all" was specified on command line and approximation was on,
ambiguity was reported. Now, "all" is recognized.
[SVN r32263]
2006-01-09 09:06:24 +00:00
Vladimir Prus
e1d38380f4
Allow to query the type of options:
...
- add new class typed_value_base, with "value_type" method
- derived typed_value from typed_value_base
Idea from Giuseppe Vacanti.
[SVN r31752]
2005-11-23 09:14:02 +00:00
Vladimir Prus
e7e1550269
Add 'extra_style_parser' method to basic_command_line_parser. Previously
...
this functionality was not available to use user due to private
derivation from detail::cmdline.
[SVN r31491]
2005-10-27 09:42:13 +00:00
Vladimir Prus
a00a6c9d19
Really make unregistered options to work.
...
- Add forwarding method allow_unregistered to the basic_command_line parser
class.
- Add new 'collect_unrecognized' function
- Add new field 'original_tokens' to the basic_option class
[SVN r31490]
2005-10-27 09:20:16 +00:00
Markus Schöpflin
78c3d90280
Fixed previous checkin.
...
[SVN r29621]
2005-06-16 13:23:17 +00:00
Markus Schöpflin
2f17c3b9b9
Added workaround for Tru64/CXX, getline() is not defined in <string> when
...
compiling in strict ansi mode. This is a bug in the string header file.
[SVN r29617]
2005-06-16 12:49:32 +00:00
Vladimir Prus
a78a1f0d76
Unroll 'make parse_command_line' const-correct patch, because it causes too
...
much troubles. Basically, consider;
char* cmdline3_[1] = {};
template<class charT>
void func(const charT* const argv[]) {}
int main()
{
func(cmdline3_);
char** p = cmdline3_;
func(p);
}
EDG compilers can't deduce template argument in the first call. See
http://thread.gmane.org/gmane.comp.lib.boost.devel/125396 for details.
Some other compilers (borland, vc 7.0) see to be have this issue too.
[SVN r29615]
2005-06-16 10:44:23 +00:00
Vladimir Prus
5af27a78e7
Use boost::throw_exception instead just throw_exception. Otherwise, borland
...
"forgets" to generate code for the function call.
[SVN r29614]
2005-06-16 10:29:49 +00:00
John Maddock
da4baad235
Added qualifier to cmdline type to fix Borland failures.
...
[SVN r28987]
2005-05-17 11:44:44 +00:00
Rene Rivera
0c1332a0d3
Some compilers don't support, or make it hard to use, source relative includes. So avoid them.
...
[SVN r28920]
2005-05-15 06:32:18 +00:00
Vladimir Prus
6b57600a81
Finally make 'allow_unregistered' method of cmdline work.
...
[SVN r28689]
2005-05-06 07:48:45 +00:00
Vladimir Prus
9a149beb76
Fix 'unknown option' error for two successive calls to 'store'.
...
The bug triggered if
- we store two parsed_option object into variables_map
- the options descriptions associated with those parsed_option objects
are different
- an option present in first parser_option object is not declared in
second options_description.
The problem was that on the second 'store' call we went over all
stored options, trying to get their description from the *second*
options description object.
Thanks to Hartmut Kaiser for the bug report.
[SVN r28685]
2005-05-06 06:40:39 +00:00
Hartmut Kaiser
dc9097c3d0
Make the True64 compiler happy.
...
[SVN r28663]
2005-05-05 16:50:41 +00:00
Vladimir Prus
d4748e8153
Fix a regression -- the if the 'style' argument to parse_command_line
...
function was zero, it was interpreted as no style is suppored. Previously,
it was interpreted as default_styles. Also, remove 'style' argument from
'cmdline' constructors.
[SVN r28500]
2005-04-27 07:02:39 +00:00
Vladimir Prus
efc9712f70
Check for invalid options in vector<option> returned by extra style
...
parser or additional parser.
[SVN r28468]
2005-04-25 09:06:44 +00:00
Vladimir Prus
94d186836e
Derive basic_command_line_parser from cmdline.
...
Eliminate 'common_command_line_parser'.
[SVN r28419]
2005-04-22 15:32:23 +00:00
Vladimir Prus
6565cbc334
Revive 'additional parser'.
...
[SVN r28415]
2005-04-22 14:05:17 +00:00
Vladimir Prus
c984d59de1
Refactor the command line parser so that it uses options_description,
...
as opposed to having his own data structures. Clean up option description
classes a bit, removing unneeded methods. Remove support for 'implicit'
options.
[SVN r28413]
2005-04-22 13:35:45 +00:00
Vladimir Prus
07778adab7
Use direct cast from any to reference, recently introduced in CVS.
...
[SVN r28411]
2005-04-22 12:56:15 +00:00
Vladimir Prus
c2442fcad6
Remove a couple of unused option_description members.
...
[SVN r27494]
2005-02-24 12:57:07 +00:00
Vladimir Prus
58d35a27b9
Change "throw" to "throw_exception".
...
[SVN r27398]
2005-02-16 09:03:19 +00:00