From 7bf6c4aa1dabef2f3abd14124b16cbf1900cf3de Mon Sep 17 00:00:00 2001 From: Morgan Deters Date: Sun, 8 Jun 2014 17:55:23 -0400 Subject: [PATCH] Better error when there are \backslashes in |quoted symbols|. --- src/parser/smt2/Smt2.g | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/parser/smt2/Smt2.g b/src/parser/smt2/Smt2.g index 39f746244..8fa047885 100644 --- a/src/parser/smt2/Smt2.g +++ b/src/parser/smt2/Smt2.g @@ -1551,8 +1551,12 @@ symbol[std::string& id, PARSER_STATE->checkDeclaration(id, check, type); } } - | UNTERMINATED_QUOTED_SYMBOL EOF - { PARSER_STATE->unexpectedEOF("unterminated |quoted| symbol"); } + | UNTERMINATED_QUOTED_SYMBOL + ( EOF + { PARSER_STATE->unexpectedEOF("unterminated |quoted| symbol"); } + | '\\' + { PARSER_STATE->unexpectedEOF("backslash not permitted in |quoted| symbol"); } + ) ; /** -- 2.30.2