diff options
author | Rustan Leino <leino@microsoft.com> | 2012-07-09 22:27:41 -0700 |
---|---|---|
committer | Rustan Leino <leino@microsoft.com> | 2012-07-09 22:27:41 -0700 |
commit | f877453f13a60e8a1d08da9cf017b35c772dddc9 (patch) | |
tree | 79dbc206a71cd22ded22e13b06b7bf38a8df6417 /Source/Dafny/Scanner.cs | |
parent | 47bb9d1c40785f56848a0f7104b6dc5c17ba0937 (diff) |
Dafny: rebuilt parser/scanner after previous merge
Diffstat (limited to 'Source/Dafny/Scanner.cs')
-rw-r--r-- | Source/Dafny/Scanner.cs | 122 |
1 files changed, 62 insertions, 60 deletions
diff --git a/Source/Dafny/Scanner.cs b/Source/Dafny/Scanner.cs index e2d1b438..1bfa80a0 100644 --- a/Source/Dafny/Scanner.cs +++ b/Source/Dafny/Scanner.cs @@ -211,8 +211,8 @@ public class UTF8Buffer: Buffer { public class Scanner {
const char EOL = '\n';
const int eofSym = 0; /* pdt */
- const int maxT = 108;
- const int noSym = 108;
+ const int maxT = 110;
+ const int noSym = 110;
[ContractInvariantMethod]
@@ -520,30 +520,32 @@ public class Scanner { case "reads": t.kind = 48; break;
case "label": t.kind = 51; break;
case "break": t.kind = 52; break;
- case "return": t.kind = 53; break;
- case "assume": t.kind = 56; break;
- case "new": t.kind = 57; break;
- case "choose": t.kind = 60; break;
- case "if": t.kind = 61; break;
- case "else": t.kind = 62; break;
- case "case": t.kind = 63; break;
- case "while": t.kind = 65; break;
- case "invariant": t.kind = 66; break;
- case "match": t.kind = 67; break;
- case "assert": t.kind = 68; break;
- case "print": t.kind = 69; break;
- case "parallel": t.kind = 70; break;
- case "in": t.kind = 83; break;
- case "false": t.kind = 93; break;
- case "true": t.kind = 94; break;
- case "null": t.kind = 95; break;
- case "this": t.kind = 96; break;
- case "fresh": t.kind = 97; break;
- case "allocated": t.kind = 98; break;
- case "old": t.kind = 99; break;
- case "then": t.kind = 100; break;
- case "forall": t.kind = 102; break;
- case "exists": t.kind = 104; break;
+ case "where": t.kind = 53; break;
+ case "return": t.kind = 54; break;
+ case "assume": t.kind = 57; break;
+ case "new": t.kind = 58; break;
+ case "choose": t.kind = 61; break;
+ case "if": t.kind = 62; break;
+ case "else": t.kind = 63; break;
+ case "case": t.kind = 64; break;
+ case "while": t.kind = 66; break;
+ case "invariant": t.kind = 67; break;
+ case "match": t.kind = 68; break;
+ case "assert": t.kind = 69; break;
+ case "print": t.kind = 70; break;
+ case "parallel": t.kind = 71; break;
+ case "in": t.kind = 84; break;
+ case "false": t.kind = 94; break;
+ case "true": t.kind = 95; break;
+ case "null": t.kind = 96; break;
+ case "this": t.kind = 97; break;
+ case "fresh": t.kind = 98; break;
+ case "allocated": t.kind = 99; break;
+ case "old": t.kind = 100; break;
+ case "then": t.kind = 101; break;
+ case "expr": t.kind = 102; break;
+ case "forall": t.kind = 104; break;
+ case "exists": t.kind = 106; break;
default: break;
}
}
@@ -663,67 +665,67 @@ public class Scanner { case 25:
{t.kind = 50; break;}
case 26:
- {t.kind = 54; break;}
- case 27:
{t.kind = 55; break;}
+ case 27:
+ {t.kind = 56; break;}
case 28:
- {t.kind = 58; break;}
- case 29:
{t.kind = 59; break;}
+ case 29:
+ {t.kind = 60; break;}
case 30:
- {t.kind = 64; break;}
+ {t.kind = 65; break;}
case 31:
if (ch == '>') {AddCh(); goto case 32;}
else {goto case 0;}
case 32:
- {t.kind = 71; break;}
- case 33:
{t.kind = 72; break;}
- case 34:
+ case 33:
{t.kind = 73; break;}
- case 35:
+ case 34:
{t.kind = 74; break;}
+ case 35:
+ {t.kind = 75; break;}
case 36:
if (ch == '&') {AddCh(); goto case 37;}
else {goto case 0;}
case 37:
- {t.kind = 75; break;}
- case 38:
{t.kind = 76; break;}
- case 39:
+ case 38:
{t.kind = 77; break;}
- case 40:
+ case 39:
{t.kind = 78; break;}
+ case 40:
+ {t.kind = 79; break;}
case 41:
- {t.kind = 80; break;}
- case 42:
{t.kind = 81; break;}
- case 43:
+ case 42:
{t.kind = 82; break;}
+ case 43:
+ {t.kind = 83; break;}
case 44:
- {t.kind = 85; break;}
- case 45:
{t.kind = 86; break;}
- case 46:
+ case 45:
{t.kind = 87; break;}
- case 47:
+ case 46:
{t.kind = 88; break;}
- case 48:
+ case 47:
{t.kind = 89; break;}
- case 49:
+ case 48:
{t.kind = 90; break;}
- case 50:
+ case 49:
{t.kind = 91; break;}
- case 51:
+ case 50:
{t.kind = 92; break;}
+ case 51:
+ {t.kind = 93; break;}
case 52:
- {t.kind = 103; break;}
- case 53:
{t.kind = 105; break;}
+ case 53:
+ {t.kind = 107; break;}
case 54:
- {t.kind = 106; break;}
+ {t.kind = 108; break;}
case 55:
- {t.kind = 107; break;}
+ {t.kind = 109; break;}
case 56:
recEnd = pos; recKind = 5;
if (ch == '=') {AddCh(); goto case 26;}
@@ -752,22 +754,22 @@ public class Scanner { if (ch == '=') {AddCh(); goto case 41;}
else {t.kind = 27; break;}
case 62:
- recEnd = pos; recKind = 84;
+ recEnd = pos; recKind = 85;
if (ch == '=') {AddCh(); goto case 42;}
else if (ch == '!') {AddCh(); goto case 43;}
- else {t.kind = 84; break;}
+ else {t.kind = 85; break;}
case 63:
recEnd = pos; recKind = 24;
if (ch == '>') {AddCh(); goto case 34;}
else {t.kind = 24; break;}
case 64:
- recEnd = pos; recKind = 101;
+ recEnd = pos; recKind = 103;
if (ch == '.') {AddCh(); goto case 23;}
- else {t.kind = 101; break;}
+ else {t.kind = 103; break;}
case 65:
- recEnd = pos; recKind = 79;
+ recEnd = pos; recKind = 80;
if (ch == '=') {AddCh(); goto case 31;}
- else {t.kind = 79; break;}
+ else {t.kind = 80; break;}
}
t.val = new String(tval, 0, tlen);
|