diff options
author | Rustan Leino <leino@microsoft.com> | 2011-11-09 10:27:00 -0800 |
---|---|---|
committer | Rustan Leino <leino@microsoft.com> | 2011-11-09 10:27:00 -0800 |
commit | 0c23ed8163bf437629cb4ef1649bcdf112eba93d (patch) | |
tree | 80ea2d7a4327678a228faef9784fba718dd25676 /Util | |
parent | 59c36ca2dca0158e5fd579f60023b31e3aab845c (diff) |
Dafny: allow single-quote as a character in identifiers in the VS2010 mode
Diffstat (limited to 'Util')
-rw-r--r-- | Util/VS2010/Dafny/DafnyLanguageService/Grammar.cs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Util/VS2010/Dafny/DafnyLanguageService/Grammar.cs b/Util/VS2010/Dafny/DafnyLanguageService/Grammar.cs index 6f9ec810..557beb32 100644 --- a/Util/VS2010/Dafny/DafnyLanguageService/Grammar.cs +++ b/Util/VS2010/Dafny/DafnyLanguageService/Grammar.cs @@ -12,7 +12,8 @@ namespace Demo #region 1. Terminals
NumberLiteral n = TerminalFactory.CreateCSharpNumber("number");
- IdentifierTerminal ident = new IdentifierTerminal("Identifier");
+ IdentifierTerminal ident = new IdentifierTerminal("Identifier", "'_?", "'_?");
+
StringLiteral stringLiteral = TerminalFactory.CreateCSharpString("String");
this.MarkReservedWords( // NOTE: these keywords must also appear once more below
@@ -351,7 +352,6 @@ namespace Demo | "==>"
| "<==>"
| "#"
- | "?" // this is not an operator, but a possible character in identifiers
| n
| stringLiteral
;
|