diff options
Diffstat (limited to 'src/options')
-rw-r--r-- | src/options/Makefile.am | 4 | ||||
-rw-r--r-- | src/options/base_options | 6 | ||||
-rw-r--r-- | src/options/base_options_handlers.h | 26 | ||||
-rw-r--r-- | src/options/option_exception.h | 2 |
4 files changed, 19 insertions, 19 deletions
diff --git a/src/options/Makefile.am b/src/options/Makefile.am index 088c972b3..eb1a2c498 100644 --- a/src/options/Makefile.am +++ b/src/options/Makefile.am @@ -156,9 +156,9 @@ endif # expression (no |, no \<, ...). Debug_tags.tmp Trace_tags.tmp: $(AM_V_GEN)\ - grep '\<$(@:_tags.tmp=) *( *\".*\" *)' \ + grep '\<$(@:_tags.tmp=)\(\.isOn\)* *( *\".*\" *)' \ `find @srcdir@/../ -name "*.cpp" -or -name "*.h" -or -name "*.cc" -or -name "*.g"` | \ - sed 's/^$(@:_tags.tmp=) *( *\"\([^"]*\)\".*/\1/;s/.*[^a-zA-Z0-9_]$(@:_tags.tmp=) *( *\"\([^"]*\)\".*/\1/' | sort | uniq >"$@" + sed 's/^$(@:_tags.tmp=)\(\.isOn\)* *( *\"\([^"]*\)\".*/\2/;s/.*[^a-zA-Z0-9_]$(@:_tags.tmp=)\(\.isOn\)* *( *\"\([^"]*\)\".*/\2/' | LC_ALL=C sort | uniq >"$@" MOSTLYCLEANFILES = \ Debug_tags \ diff --git a/src/options/base_options b/src/options/base_options index 10ad564e6..59fadf40b 100644 --- a/src/options/base_options +++ b/src/options/base_options @@ -71,9 +71,9 @@ option in std::istream* :default &std::cin :include <iostream> option out std::ostream* :default &std::cout :include <iostream> option err std::ostream* :default &std::cerr :include <iostream> -common-option inputLanguage -L --lang=LANG InputLanguage :handler CVC4::options::stringToInputLanguage :include "util/language.h" :default language::input::LANG_AUTO :read-write +common-option inputLanguage input-language -L --lang=LANG InputLanguage :handler CVC4::options::stringToInputLanguage :include "util/language.h" :default language::input::LANG_AUTO :read-write force input language (default is "auto"; see --lang help) -common-option outputLanguage --output-lang=LANG OutputLanguage :handler CVC4::options::stringToOutputLanguage :include "util/language.h" :default language::output::LANG_AUTO :read-write +common-option outputLanguage output-language --output-lang=LANG OutputLanguage :handler CVC4::options::stringToOutputLanguage :include "util/language.h" :default language::output::LANG_AUTO :read-write force input language (default is "auto"; see --lang help) option languageHelp bool @@ -84,7 +84,7 @@ common-option - -v --verbose void :handler CVC4::options::increaseVerbosity common-option - -q --quiet void :handler CVC4::options::decreaseVerbosity decrease verbosity (may be repeated) -common-option statistics stats --stats bool +common-option statistics statistics --stats bool give statistics on exit common-option parseOnly parse-only --parse-only bool :read-write diff --git a/src/options/base_options_handlers.h b/src/options/base_options_handlers.h index 5f82280da..6cb74c637 100644 --- a/src/options/base_options_handlers.h +++ b/src/options/base_options_handlers.h @@ -38,22 +38,22 @@ inline void decreaseVerbosity(std::string option, SmtEngine* smt) { } inline OutputLanguage stringToOutputLanguage(std::string option, std::string optarg, SmtEngine* smt) throw(OptionException) { - if(optarg == "cvc4" || optarg == "pl") { + if(optarg == "cvc4" || optarg == "pl" || optarg == "presentation" || optarg == "LANG_CVC4") { return language::output::LANG_CVC4; - } else if(optarg == "smtlib" || optarg == "smt") { + } else if(optarg == "smtlib" || optarg == "smt" || optarg == "LANG_SMTLIB") { return language::output::LANG_SMTLIB; - } else if(optarg == "smtlib2" || optarg == "smt2") { + } else if(optarg == "smtlib2" || optarg == "smt2" || optarg == "LANG_SMTLIB_V2") { return language::output::LANG_SMTLIB_V2; - } else if(optarg == "tptp") { + } else if(optarg == "tptp" || optarg == "LANG_TPTP") { return language::output::LANG_TPTP; - } else if(optarg == "ast") { + } else if(optarg == "ast" || optarg == "LANG_AST") { return language::output::LANG_AST; - } else if(optarg == "auto") { + } else if(optarg == "auto" || optarg == "LANG_AUTO") { return language::output::LANG_AUTO; } if(optarg != "help") { - throw OptionException(std::string("unknown language for --output-lang: `") + + throw OptionException(std::string("unknown language for ") + option + ": `" + optarg + "'. Try --output-lang help."); } @@ -62,20 +62,20 @@ inline OutputLanguage stringToOutputLanguage(std::string option, std::string opt } inline InputLanguage stringToInputLanguage(std::string option, std::string optarg, SmtEngine* smt) throw(OptionException) { - if(optarg == "cvc4" || optarg == "pl" || optarg == "presentation") { + if(optarg == "cvc4" || optarg == "pl" || optarg == "presentation" || optarg == "LANG_CVC4") { return language::input::LANG_CVC4; - } else if(optarg == "smtlib" || optarg == "smt") { + } else if(optarg == "smtlib" || optarg == "smt" || optarg == "LANG_SMTLIB") { return language::input::LANG_SMTLIB; - } else if(optarg == "smtlib2" || optarg == "smt2") { + } else if(optarg == "smtlib2" || optarg == "smt2" || optarg == "LANG_SMTLIB_V2") { return language::input::LANG_SMTLIB_V2; - } else if(optarg == "tptp") { + } else if(optarg == "tptp" || optarg == "LANG_TPTP") { return language::input::LANG_TPTP; - } else if(optarg == "auto") { + } else if(optarg == "auto" || optarg == "LANG_AUTO") { return language::input::LANG_AUTO; } if(optarg != "help") { - throw OptionException(std::string("unknown language for --lang: `") + + throw OptionException(std::string("unknown language for ") + option + ": `" + optarg + "'. Try --lang help."); } diff --git a/src/options/option_exception.h b/src/options/option_exception.h index 657bc7568..6aaa7d7e2 100644 --- a/src/options/option_exception.h +++ b/src/options/option_exception.h @@ -49,7 +49,7 @@ public: } UnrecognizedOptionException(const std::string& msg) : - CVC4::OptionException(msg) { + CVC4::OptionException("Unrecognized informational or option key or setting: " + msg) { } };/* class UnrecognizedOptionException */ |