mirror of
https://github.com/Z3Prover/z3
synced 2025-04-27 10:55:50 +00:00
seq API
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
parent
5e553a4dc1
commit
e10ecad5dc
14 changed files with 745 additions and 44 deletions
|
@ -169,24 +169,16 @@ namespace smt2 {
|
|||
char c = curr();
|
||||
if (c == EOF)
|
||||
throw scanner_exception("unexpected end of string", m_line, m_spos);
|
||||
if (c == '\"') {
|
||||
if (c == '\n') {
|
||||
new_line();
|
||||
}
|
||||
else if (c == '\"') {
|
||||
next();
|
||||
if (curr() != '\"') {
|
||||
m_string.push_back(0);
|
||||
return STRING_TOKEN;
|
||||
}
|
||||
}
|
||||
else if (c == '\n') {
|
||||
new_line();
|
||||
}
|
||||
else if (c == '\\') {
|
||||
next();
|
||||
c = curr();
|
||||
if (c == EOF)
|
||||
throw scanner_exception("unexpected end of string", m_line, m_spos);
|
||||
if (c != '\\' && c != '\"')
|
||||
throw scanner_exception("invalid escape sequence", m_line, m_spos);
|
||||
}
|
||||
m_string.push_back(c);
|
||||
next();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue