eliminated Token.Location.getContext()
authoradam <adam@megacz.com>
Mon, 2 Jan 2006 06:53:27 +0000 (01:53 -0500)
committeradam <adam@megacz.com>
Mon, 2 Jan 2006 06:53:27 +0000 (01:53 -0500)
darcs-hash:20060102065327-5007d-ecedeead6e7d086fb83123c41672ce3fd781750b.gz

src/edu/berkeley/sbp/Parser.java
src/edu/berkeley/sbp/Token.java

index 6bf274d..a54fa08 100644 (file)
@@ -62,7 +62,7 @@ public abstract class Parser<T extends Token, R> {
         public Failed() { this("", null); }
         public Failed(String message, Token.Location loc) { this.location = loc; this.message = message; }
         public Token.Location getLocation() { return location; }
         public Failed() { this("", null); }
         public Failed(String message, Token.Location loc) { this.location = loc; this.message = message; }
         public Token.Location getLocation() { return location; }
-        public String toString() { return message + (location==null ? "" : (" at " + location + "\n" + location.getContext())); }
+        public String toString() { return message + (location==null ? "" : (" at " + location)); }
     }
 
     public static class Ambiguous extends RuntimeException {
     }
 
     public static class Ambiguous extends RuntimeException {
index 07edde3..faa02b9 100644 (file)
@@ -23,7 +23,6 @@ public interface Token {
     /** a location within the input stream */
     public static interface Location {
         public String toString();
     /** a location within the input stream */
     public static interface Location {
         public String toString();
-        public String getContext();
     }
 
 }
     }
 
 }