options: fix missing error_type
This commit is contained in:
parent
1311bd7a64
commit
5c46026ea5
1 changed files with 2 additions and 1 deletions
|
|
@ -6,9 +6,10 @@
|
||||||
ztd::option_error::option_error(error_type type, const std::string& option)
|
ztd::option_error::option_error(error_type type, const std::string& option)
|
||||||
{
|
{
|
||||||
opt=option;
|
opt=option;
|
||||||
|
errtype=type;
|
||||||
switch(type)
|
switch(type)
|
||||||
{
|
{
|
||||||
case unknown_option : msg = "Unkown option: " + opt; break;
|
case unknown_option : msg = "Unknown option: " + opt; break;
|
||||||
case takes_no_arg : msg = "Option " + opt + " doesn't take an argument"; break;
|
case takes_no_arg : msg = "Option " + opt + " doesn't take an argument"; break;
|
||||||
case missing_arg : msg = "Option " + opt + " needs an argument"; break;
|
case missing_arg : msg = "Option " + opt + " needs an argument"; break;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue