Added column number to exception thrown in Match
authorMichael Welch <michaelgwelch@gmail.com>
Thu, 28 Dec 2006 22:58:01 +0000 (22:58 +0000)
committerMichael Welch <michaelgwelch@gmail.com>
Thu, 28 Dec 2006 22:58:01 +0000 (22:58 +0000)
mbasic/Parser.cs

index 34ef484..f77a205 100644 (file)
@@ -55,7 +55,8 @@ namespace mbasic
             if (lookahead == Token.EOF && t == Token.EndOfLine) return;
 
             if (lookahead == t) lookahead = lexer.Next();
-            else throw new Exception(String.Format("Parsing exception on label {0}", lexer.LineId.Label));
+            else throw new Exception(String.Format("Parsing exception on label {0}, column {1}"
+                , lexer.LineId.Label, lexer.Column));
         }
 
         private Statement Statement()