diff options
author | Tim King <taking@cs.nyu.edu> | 2018-01-06 15:27:11 -0800 |
---|---|---|
committer | Andrew Reynolds <andrew.j.reynolds@gmail.com> | 2018-01-06 17:27:11 -0600 |
commit | 8497910df4d1c254b26f09c3dc5ee6191c970b12 (patch) | |
tree | 495df915de750ad09ade2d9f8844365e5feaeb76 /src/parser/parser.h | |
parent | d26e19150d5d3a6cc8cee332a5f2067a7383a129 (diff) |
Removing throw specifiers from src/parser/. (#1486)
Diffstat (limited to 'src/parser/parser.h')
-rw-r--r-- | src/parser/parser.h | 31 |
1 files changed, 14 insertions, 17 deletions
diff --git a/src/parser/parser.h b/src/parser/parser.h index f2044c7ef..7f64b9580 100644 --- a/src/parser/parser.h +++ b/src/parser/parser.h @@ -400,9 +400,10 @@ public: * @param notes notes to add to a parse error (if one is generated) * @throws ParserException if checks are enabled and the check fails */ - void checkDeclaration(const std::string& name, DeclarationCheck check, + void checkDeclaration(const std::string& name, + DeclarationCheck check, SymbolType type = SYM_VARIABLE, - std::string notes = "") throw(ParserException); + std::string notes = ""); /** * Reserve a symbol at the assertion level. @@ -418,7 +419,7 @@ public: * @throws ParserException if checks are enabled and fun is not * a function */ - void checkFunctionLike(Expr fun) throw(ParserException); + void checkFunctionLike(Expr fun); /** * Check that <code>kind</code> can accept <code>numArgs</code> arguments. @@ -428,7 +429,7 @@ public: * <code>kind</code> cannot be applied to <code>numArgs</code> * arguments. */ - void checkArity(Kind kind, unsigned numArgs) throw(ParserException); + void checkArity(Kind kind, unsigned numArgs); /** * Check that <code>kind</code> is a legal operator in the current @@ -439,7 +440,7 @@ public: * @throws ParserException if the parser mode is strict and the * operator <code>kind</code> has not been enabled */ - void checkOperator(Kind kind, unsigned numArgs) throw(ParserException); + void checkOperator(Kind kind, unsigned numArgs); /** Create a new CVC4 variable expression of the given type. * @@ -671,26 +672,21 @@ public: bool isPredicate(const std::string& name); /** Parse and return the next command. */ - Command* nextCommand() throw(ParserException, UnsafeInterruptException); + Command* nextCommand(); /** Parse and return the next expression. */ - Expr nextExpression() throw(ParserException, UnsafeInterruptException); + Expr nextExpression(); /** Issue a warning to the user. */ - inline void warning(const std::string& msg) { - d_input->warning(msg); - } - + void warning(const std::string& msg) { d_input->warning(msg); } /** Issue a warning to the user, but only once per attribute. */ void attributeNotSupported(const std::string& attr); /** Raise a parse error with the given message. */ - inline void parseError(const std::string& msg) throw(ParserException) { - d_input->parseError(msg); - } - + inline void parseError(const std::string& msg) { d_input->parseError(msg); } /** Unexpectedly encountered an EOF */ - inline void unexpectedEOF(const std::string& msg) throw(ParserException) { + inline void unexpectedEOF(const std::string& msg) + { d_input->parseError(msg, true); } @@ -708,7 +704,8 @@ public: * support parsing quantifiers (just not doing anything with them). * So this mechanism gives you a way to do it with --parse-only. */ - inline void unimplementedFeature(const std::string& msg) throw(ParserException) { + inline void unimplementedFeature(const std::string& msg) + { if(!d_parseOnly) { parseError("Unimplemented feature: " + msg); } |