[e-cvs] cvs commit: e/src/jsrc/org/quasiliteral/term TermSchema.java TermLexer.java TermParser.java term.y

markm@eros.cs.jhu.edu markm@eros.cs.jhu.edu
Sun, 2 Dec 2001 13:42:03 -0500


markm       01/12/02 13:42:02

  Modified:    src/jsrc Makefile
               src/jsrc/org/erights/e/elang/interp InteractiveInterp.java
                        Interp.java
               src/jsrc/org/erights/e/elang/syntax EBuilder.java
                        ELexer.java EParser.java PrettyFeeder.java
                        QuasiFeeder.java e.y
               src/jsrc/org/erights/e/ui/elmer EInterpAdapter.java
               src/jsrc/org/quasiliteral/astro AstroSchema.java
                        BaseSchema.java
               src/jsrc/org/quasiliteral/term TermLexer.java
                        TermParser.java term.y
  Added:       src/jsrc/org/quasiliteral/syntax BaseLexer.java
                        FileFeeder.java Indenter.java LineFeeder.java
                        NeedMoreException.java SyntaxException.java
                        TwineFeeder.java
               src/jsrc/org/quasiliteral/term TermSchema.java
  Removed:     src/jsrc/org/erights/e/elang/syntax FileFeeder.java
                        Indenter.java LineFeeder.java
                        NeedMoreException.java SyntaxException.java
                        TwineFeeder.java
  Log:
  Just snapshotting an intermediate, non-working state.  Towards reconstruction of the TermParser.

Revision  Changes    Path
1.61      +2 -1      e/src/jsrc/Makefile

Index: Makefile
===================================================================
RCS file: /cvs/e/src/jsrc/Makefile,v
retrieving revision 1.60
retrieving revision 1.61
diff -u -r1.60 -r1.61
--- Makefile	2001/12/01 10:38:41	1.60
+++ Makefile	2001/12/02 18:42:01	1.61
@@ -50,7 +50,8 @@
 # optional: remake the parsers from yacc, or just use the generated
 # ones, which are included.
 elang_parser:
-	find org/quasiliteral/astro -name '*.java' > files.tmp
+	find org/quasiliteral/astro  -name '*.java' > files.tmp
+	find org/quasiliteral/syntax -name '*.java' >> files.tmp
 	$(JCOMPILE) @files.tmp
 	# (cd $(TOP)/src/jsrc/org/quasiliteral/term; $(MAKE) all)
 	(cd $(ER)/elang/syntax; $(MAKE) all)



1.16      +3 -3      e/src/jsrc/org/erights/e/elang/interp/InteractiveInterp.java

Index: InteractiveInterp.java
===================================================================
RCS file: /cvs/e/src/jsrc/org/erights/e/elang/interp/InteractiveInterp.java,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -r1.15 -r1.16
--- InteractiveInterp.java	2001/12/02 06:01:43	1.15
+++ InteractiveInterp.java	2001/12/02 18:42:01	1.16
@@ -27,9 +27,9 @@
 import org.erights.e.elang.scope.Scope;
 import org.erights.e.elang.syntax.ELexer;
 import org.erights.e.elang.syntax.EParser;
-import org.erights.e.elang.syntax.FileFeeder;
-import org.erights.e.elang.syntax.LineFeeder;
-import org.erights.e.elang.syntax.NeedMoreException;
+import org.quasiliteral.syntax.FileFeeder;
+import org.quasiliteral.syntax.LineFeeder;
+import org.quasiliteral.syntax.NeedMoreException;
 import org.erights.e.elib.eio.TextWriter;
 import org.erights.e.elib.prim.E;
 import org.erights.e.elib.prim.FERunner;



1.79      +2 -2      e/src/jsrc/org/erights/e/elang/interp/Interp.java

Index: Interp.java
===================================================================
RCS file: /cvs/e/src/jsrc/org/erights/e/elang/interp/Interp.java,v
retrieving revision 1.78
retrieving revision 1.79
diff -u -r1.78 -r1.79
--- Interp.java	2001/12/02 05:32:05	1.78
+++ Interp.java	2001/12/02 18:42:01	1.79
@@ -28,8 +28,8 @@
 import org.erights.e.elang.scope.Scope;
 import org.erights.e.elang.syntax.ELexer;
 import org.erights.e.elang.syntax.EParser;
-import org.erights.e.elang.syntax.FileFeeder;
-import org.erights.e.elang.syntax.LineFeeder;
+import org.quasiliteral.syntax.FileFeeder;
+import org.quasiliteral.syntax.LineFeeder;
 import org.erights.e.elib.eio.TextWriter;
 import org.erights.e.elib.prim.BERunner;
 import org.erights.e.elib.prim.E;



1.88      +1 -0      e/src/jsrc/org/erights/e/elang/syntax/EBuilder.java

Index: EBuilder.java
===================================================================
RCS file: /cvs/e/src/jsrc/org/erights/e/elang/syntax/EBuilder.java,v
retrieving revision 1.87
retrieving revision 1.88
diff -u -r1.87 -r1.88
--- EBuilder.java	2001/12/02 06:01:44	1.87
+++ EBuilder.java	2001/12/02 18:42:01	1.88
@@ -64,6 +64,7 @@
 import org.erights.e.elib.tables.FlexMap;
 import org.erights.e.elib.tables.Twine;
 import org.quasiliteral.astro.AstroToken;
+import org.quasiliteral.syntax.SyntaxException;
 
 /**
  * Build E parse-trees.  As a notational hack, EParser inherits from



1.69      +36 -679   e/src/jsrc/org/erights/e/elang/syntax/ELexer.java

Index: ELexer.java
===================================================================
RCS file: /cvs/e/src/jsrc/org/erights/e/elang/syntax/ELexer.java,v
retrieving revision 1.68
retrieving revision 1.69
diff -u -r1.68 -r1.69
--- ELexer.java	2001/12/02 06:01:44	1.68
+++ ELexer.java	2001/12/02 18:42:01	1.69
@@ -25,12 +25,16 @@
 import org.erights.e.elib.tables.Twine;
 import org.quasiliteral.astro.AstroSchema;
 import org.quasiliteral.astro.AstroToken;
-import org.quasiliteral.astro.BaseSchema;
+import org.quasiliteral.astro.AstroTag;
+import org.quasiliteral.syntax.BaseLexer;
+import org.quasiliteral.syntax.FileFeeder;
+import org.quasiliteral.syntax.LineFeeder;
+import org.quasiliteral.syntax.SyntaxException;
+import org.quasiliteral.syntax.TwineFeeder;
 
 import java.io.BufferedReader;
 import java.io.FileReader;
 import java.io.IOException;
-import java.math.BigInteger;
 
 /**
  * Breaks textually input into a stream of tokens according to the E
@@ -38,92 +42,21 @@
  *
  * @author <a href="mailto:markm@erights.org">Mark S. Miller</a>
  */
-public class ELexer {
+public class ELexer extends BaseLexer {
 
     /**
      *
      */
-    static public final int EOFCHAR = -1;
-
-    /**
-     *
-     */
     static private final String QUASI_ENDER = "$@`";
 
     /**
      *
      */
-    static public final AstroSchema DEFAULT_SCHEMA =
-      new BaseSchema(EParser.getTokenNames());
-
-    /** contains all lines after the current line */
-    private LineFeeder myInput;
-
-    /** the current line, or null at end-of-file */
-    public Twine myLTwine = null;
-
-    /** the string part, but as an array for speed */
-    public char[] myLData = null;
-
-    /** position in current line of candidate character */
-    private int myPos;
-
-    /** the candidate character, or EOFCHAR for end-of-file. */
-    private int myChar;
-
-    /**
-     * Where on the current line does the current token start?  If the token
-     * starts before the current line, or if there is no current token, this
-     * is -1.
-     */
-    private int myOptStartPos = -1;
-
-    /**
-     * Accumulates all text of the current token from lines before the
-     * current line, or null if no current token or if the current
-     * token starts on the current line.  The EOL token itself is not
-     * considered to be a line spanning token.
-     */
-    private Twine myOptStartText = null;
-
-    /**
-     * Is there a nextChar() that's been delayed?
-     */
-    private boolean myDelayedNextChar = false;
-
-    /**
-     *
-     */
-    private boolean myPartialFlag;
-
-    /**
-     * Should tabs be rejected as valid whitespace?
-     */
-    private boolean myNoTabsFlag;
-
-    /**
-     * Keeps track of indentation level
-     */
-    private Indenter myIndenter;
-
-    /**
-     * Should the next line get extra indentation as a continuation line?
-     */
-    private boolean myContinueFlag;
-
-    /**
-     *
-     */
-    private AstroSchema mySchema;
-
-    /**
-     *
-     */
     public ELexer(LineFeeder input,
                   boolean partialFlag,
                   boolean noTabsFlag)
       throws IOException {
-        this(input, partialFlag, noTabsFlag, DEFAULT_SCHEMA);
+        this(input, partialFlag, noTabsFlag, EParser.DEFAULT_SCHEMA);
     }
 
     /**
@@ -134,21 +67,7 @@
                   boolean noTabsFlag,
                   AstroSchema schema)
       throws IOException {
-
-        myInput = input;
-        myPos = -1;
-        myPartialFlag = partialFlag;
-        myLTwine = myInput.optNextLine(false, 0, 'x', 0);
-        if (null == myLTwine) {
-            myLData = null;
-        } else {
-            myLData = myLTwine.bare().toCharArray();
-        }
-        nextChar();
-        myNoTabsFlag = noTabsFlag;
-        myIndenter = new Indenter();
-        myContinueFlag = false;
-        mySchema = schema;
+        super(input, partialFlag, noTabsFlag, schema);
     }
 
     /**
@@ -170,273 +89,16 @@
     }
 
     /**
-     * Does not affect the partial flag
-     */
-    public void setSource(Twine newSource) {
-        TwineFeeder feeder = new TwineFeeder(newSource);
-
-        myInput = feeder;
-        myPos = -1;
-        // myPartialFlag = ??;
-        myLTwine = feeder.optNextLine(false, 0, 'x', 0);
-        if (null == myLTwine) {
-            myLData = null;
-        } else {
-            myLData = myLTwine.bare().toCharArray();
-        }
-        myOptStartPos = -1;
-        myOptStartText = null;
-        myDelayedNextChar = true; //rather than doing nextChar() ourselves
-        myIndenter = new Indenter();
-        myContinueFlag = false;
-    }
-
-    /**
-     * Skip to the end of this line, so that the next character read will be
-     * from the next line, forget any token we may have been in the midst
-     * of, and reset our indentation tracker.
-     */
-    private void reset() {
-        if (null != myLTwine) {
-            myPos = myLData.length;
-        }
-        myOptStartPos = -1;
-        myOptStartText = null;
-        myDelayedNextChar = true;
-        myIndenter = new Indenter();
-        myContinueFlag = false;
-    }
-
-    /**
-     *
-     */
-    private void nextLine() throws IOException {
-        if (myLTwine == null) {
-            myChar = EOFCHAR;
-            return;
-        }
-        if (-1 == myOptStartPos) {
-            if (null == myOptStartText) {
-                //no current token, do nothing
-            } else {
-                //current token already started
-                myOptStartText = (Twine)myOptStartText.add(myLTwine);
-            }
-        } else {
-            //current token started on this line at myOptStartPos
-            myOptStartText = (Twine)myLTwine.run(myOptStartPos,
-                                                 myLTwine.size());
-            myOptStartPos = -1;
-        }
-        myPos = -1;
-
-        //This is irritatingly redundant with needMore(..).
-        //XXX Need to refactor, but how?
-        char closer = myIndenter.getCloser();
-        int indent = myIndenter.getIndent();
-        if (myContinueFlag) {
-            indent += 2;
-        }
-        myLTwine =
-          myInput.optNextLine(('"' == closer || '`' == closer),
-                              indent,
-                              closer,
-                              myIndenter.getCloseIndent());
-
-        if (null == myLTwine) {
-            //don't clear myContinueFlag on end-of-file
-            myLData = null;
-        } else {
-            myContinueFlag = false;
-            myLData = myLTwine.bare().toCharArray();
-        }
-        myChar = '\n';
-    }
-
-    /**
-     *
-     */
-    private void nextChar() throws IOException {
-        while (true) {
-            if (null == myLTwine) {
-                myChar = EOFCHAR;
-                return;
-            }
-            myPos++;
-            int len = myLData.length;
-            if (myPos < len) {
-                myChar = myLData[myPos];
-                return;
-            } else {
-                nextLine();
-            }
-        }
-    }
-
-    /**
-     *
-     */
-    public AstroToken nextToken() throws IOException, SyntaxException {
-        AstroToken result;
-        try {
-            result = getNextToken();
-        } finally {
-            myOptStartPos = -1;
-            myOptStartText = null;
-        }
-        if (EParser.isContinuer(result.getType())) {
-            return continuer(result);
-        } else {
-            return result;
-        }
-    }
-
-    /**
-     * Separated out for use by '>'
-     */
-    private AstroToken continuer(AstroToken result) throws IOException {
-        if (isWhite(myPos, myLData.length)) {
-            myContinueFlag = true;
-            skipLine();
-        }
-        return result;
-    }
-
-    /**
-     *
-     */
-    /*package*/
-    void syntaxError(String msg) throws SyntaxException {
-        int start = myOptStartPos;
-        if (-1 == start) {
-            start = myPos - 1;
-        }
-        start = Math.max(Math.min(start, myPos - 1), 0);
-        int bound = Math.max(myPos, start + 1);
-        SyntaxException sex = new SyntaxException(msg,
-                                                  myLTwine,
-                                                  start,
-                                                  bound);
-        reset();
-        throw sex;
-    }
-
-    /**
-     * nest defaults to -1, meaning "unknown"
-     */
-    /*package*/
-    void needMore(String msg)
-      throws NeedMoreException, SyntaxException {
-        if (myPartialFlag) {
-
-            //This is irritatingly redundant with nextLine().
-            //XXX Need to refactor, but how?
-            char closer = myIndenter.getCloser();
-            int indent = myIndenter.getIndent();
-            if (myContinueFlag) {
-                indent += 2;
-                myContinueFlag = false;
-            }
-            NeedMoreException nme =
-              new NeedMoreException(msg,
-                                    ('"' == closer || '`' == closer),
-                                    indent,
-                                    closer,
-                                    myIndenter.getCloseIndent());
-            reset();
-            throw nme;
-        } else {
-            syntaxError(msg);
-        }
-    }
-
-    /**
-     *
-     */
-    private boolean eatDigit(int radix) throws IOException {
-        if (Character.digit((char)myChar, radix) != -1 || myChar == '_') {
-            nextChar();
-            return true;
-        } else {
-            return false;
-        }
-    }
-
-    /**
-     *
-     */
-    private void skipWhiteSpace() throws IOException {
-        while (true) {
-            if (myChar == EOFCHAR) {
-                return;
-            }
-            if (Character.isWhitespace((char)myChar)) {
-                if (myChar == '\n') {
-                    return;
-                }
-                if (myChar == '\t') {
-                    if (myNoTabsFlag) {
-                        syntaxError
-                          ("The optional e.enable.notabs feature" +
-                           " in eprops.txt is currently on,\n" +
-                           "so tabs are not considered valid whitespace");
-                    }
-                    //else, we should warn, but XXX we don't yet have a
-                    //warning mechanism.
-                }
-                nextChar();
-            } else {
-                if ((myChar == '?' || myChar == '>') && isWhite(0, myPos)) {
-                    //Is the first non-whitespace character on this line a
-                    //'?' or '>'?
-                    //If yes, so treat it as an updoc line
-                    skipLine();
-                } else {
-                    //If not, treat it normally.
-                    return;
-                }
-            }
-        }
-    }
-
-    /**
-     * Are all the characters on the current line from start inclusive to
-     * bound exclusive whitespace characters?
-     */
-    private boolean isWhite(int start, int bound) {
-        for (int i = start; i < bound; i++) {
-            if (!Character.isWhitespace(myLData[i])) {
-                return false;
-            }
-        }
-        return true;
-    }
-
-    /**
      *
      */
-    private AstroToken leafTag(int typeCode, Twine source) {
-        return (AstroToken)mySchema.leafTag(typeCode, source);
+    protected boolean isContinuer(int tokenType) {
+        return EParser.isContinuer(tokenType);
     }
 
     /**
      *
      */
-    private AstroToken leafData(Object data, Twine source) {
-        return (AstroToken)mySchema.leafData(data, source);
-    }
-
-    /**
-     *
-     */
-    private AstroToken composite(int typeCode, Object data, Twine source) {
-        return (AstroToken)mySchema.composite(typeCode, data, source);
-    }
-
-    /**
-     *
-     */
-    private AstroToken getNextToken() throws IOException, SyntaxException {
+    protected AstroToken getNextToken() throws IOException, SyntaxException {
         if (myDelayedNextChar) {
             nextChar();
             myDelayedNextChar = false;
@@ -511,7 +173,7 @@
                           isIdentifierPart((char)myChar));
                         Twine name = endToken();
                         String key = name.bare().substring(1);
-                        int tt = EParser.optKeywordType(key);
+                        int tt = optKeywordType(key);
                         if (tt != -1) {
                             syntaxError(key + " is a keyword");
                         }
@@ -545,7 +207,7 @@
                           isIdentifierPart((char)myChar));
                         Twine name = endToken();
                         String key = name.bare().substring(1);
-                        int tt = EParser.optKeywordType(key);
+                        int tt = optKeywordType(key);
                         if (tt != -1) {
                             syntaxError(key + " is a keyword");
                         }
@@ -728,8 +390,8 @@
                         syntaxError("\\u... not yet implemented");
                         return null; //keep compiler happy
                     }
-                    //an escaped newline is insensitive to trailing whitespace,
-                    //since that's invisible anyway.
+                    //an escaped newline is insensitive to trailing
+                    //whitespace, since that's invisible anyway.
                     skipWhiteSpace();
                     if (myChar == '\n') {
                         myContinueFlag = true;
@@ -789,7 +451,8 @@
                         nextChar();
                         return leafTag(EParser.MatchBind, endToken());
                     }
-                    syntaxError("use ':=' for assignment, or '==' for equality");
+                    syntaxError
+                      ("use ':=' for assignment, or '==' for equality");
                     return null; //keep compiler happy
                 }
             case '&':
@@ -830,8 +493,8 @@
             case '`':
                 {
                     //eat the backquote here so quasiPart can also
-                    //be called when we're continuing after a hole, in which case
-                    //there is no leading backquote.
+                    //be called when we're continuing after a hole, in which
+                    //case there is no leading backquote.
                     nextChar();
                     Twine openner = (Twine)myLTwine.run(myOptStartPos, myPos);
                     myIndenter.push(openner, '`', 0);
@@ -849,7 +512,6 @@
             case '9':
                 {
                     return numberLiteral();
-
                 }
             case '_':
                 {
@@ -866,14 +528,14 @@
                         return leafTag(EParser.OpFlrDiv, endToken());
                     }
                     return leafTag(EParser._, endToken());
-
                 }
             default:
                 {
                     if (isIdentifierStart((char)myChar)) {
                         return identifier();
                     } else {
-                        syntaxError("unrecognized character: '" + (char)myChar +
+                        syntaxError("unrecognized character: '" +
+                                    (char)myChar +
                                     "' code: " + (int)myChar);
                         return null; //keep compiler happy
                     }
@@ -881,118 +543,26 @@
         }
     }
 
-    /**
-     *
-     */
-    private AstroToken openBracket(char closer) throws IOException {
-        int tokenType = myChar;
-        nextChar();
-        Twine openner = endToken();
-        return openBracket(tokenType, openner, closer);
-    }
-
     /**
-     *
-     */
-    private AstroToken openBracket(int tokenType, Twine openner, char closer)
-      throws IOException {
-        if (isWhite(myPos, myLData.length)) {
-            myIndenter.nest(openner, closer);
+     * If 'name' is a keyword, return it's token type code, else -1.
+     * <p>
+     * Note that E keywords are case insensitive, so 'name' is first
+     * toLowerCase()d.
+     */
+    private int optKeywordType(String name) {
+        name = name.toLowerCase();
+        AstroTag optTag = mySchema.getOptTagForName(name);
+        if (null == optTag) {
+            return -1;
         } else {
-            //Indent the next line to right after the open.
-            myIndenter.push(openner, closer, myPos);
+            return optTag.getOptTypeCode();
         }
-        return leafTag(tokenType, openner);
-    }
-
-    /**
-     *
-     */
-    private AstroToken closeBracket() throws IOException {
-        char closerChar = (char)myChar;
-        nextChar();
-        Twine closer = endToken();
-        //on mismatched close, throws SyntaxError at openner
-        //on unmatched close, throws Syntax error at closer
-        myIndenter.pop(closerChar, closer);
-        return leafTag(closerChar, closer);
     }
 
     /**
-     *
-     */
-    private char charConstant() throws IOException, SyntaxException {
-        if (myChar == '\\') {
-            nextChar();
-            switch (myChar) {
-                case 'b':
-                    return '\b';
-                case 't':
-                    return '\t';
-                case 'n':
-                    return '\n';
-                case 'f':
-                    return '\f';
-                case 'r':
-                    return '\r';
-                case '"':
-                    return '"';
-                case '\'':
-                    return '\'';
-                case '\\':
-                    return '\\';
-                case '\n':
-                    {
-                        //XXX need to move into stringLiteral only
-                        //XXX bug: must be accepted at end of string
-                        nextChar();
-                        return charConstant();
-                    }
-                case EOFCHAR:
-                    {
-                        syntaxError("End of file in middle of literal");
-                    }
-                case 'u':
-                    {
-                        syntaxError
-                          ("XXX escaped uchar codes not yet implemented");
-                    }
-                default:
-                    {
-                        if (Character.isDigit((char)myChar)) {
-                            syntaxError
-                              ("XXX escaped char codes not yet implemented");
-                        } else {
-                            syntaxError("Unrecognized escaped character");
-                        }
-                    }
-            }
-        } else if (myChar == EOFCHAR) {
-            syntaxError("End of file in middle of literal");
-        } else {
-            return (char)myChar;
-        }
-        return 'x'; //keep compiler happy
-    }
-
-    /**
-     *
-     */
-    private AstroToken charLiteral() throws IOException, SyntaxException {
-        nextChar();
-        char value = charConstant();
-        nextChar();
-        if (myChar != '\'') {
-            syntaxError("char constant must end in \"'\"");
-        }
-        nextChar();
-        return leafData(new Character(value), endToken());
-    }
-
-    /**
      * Called with myChar as the first character of the identifier.
      */
-    private AstroToken identifier() throws IOException, SyntaxException {
+    protected AstroToken identifier() throws IOException, SyntaxException {
         do {
             nextChar();
         } while (myChar != EOFCHAR && isIdentifierPart((char)myChar));
@@ -1005,7 +575,7 @@
                 nextChar();
                 Twine source = endToken();
                 String name = source.bare().substring(0, source.size() - 1);
-                int tt = EParser.optKeywordType(name);
+                int tt = optKeywordType(name);
                 if (tt != -1) {
                     syntaxError(name + " is a keyword");
                 }
@@ -1013,7 +583,7 @@
             }
         }
         Twine source = endToken();
-        int ttype = EParser.optKeywordType(source.bare());
+        int ttype = optKeywordType(source.bare());
         if (-1 == ttype) {
             return composite(EParser.ID, source.bare(), source);
         } else {
@@ -1022,143 +592,7 @@
         }
     }
 
-    /** pretty self explanatory */
-    public boolean isEndOfFile() {
-        return null == myLTwine;
-    }
-
-    /**
-     * The first character of an E identifier may be anything accepted
-     * as the first character of a Java identifier except '$'.  I.e.,
-     * a letter or '_'.
-     *
-     * @see java.lang.Character#isJavaIdentifierStart
-     */
-    static public boolean isIdentifierStart(char ch) {
-        return Character.isJavaIdentifierStart(ch) && ch != '$';
-    }
-
-    /**
-     * A non-first character of an E identifier may be anything
-     * accepted as a non-first character of a Java identifier except
-     * '$'. The ascii subset consists of letters, digits, and '_'.
-     * See Character.isJavaIdentifierPart() for the full spec.
-     *
-     * @see java.lang.Character#isJavaIdentifierPart
-     */
-    static public boolean isIdentifierPart(char ch) {
-        return Character.isJavaIdentifierPart(ch) && ch != '$';
-    }
-
-//    /**
-//     * A legal E identifier is a non-keyword string whose first character
-//     * isIdentifierStart, the rest of whose characters are
-//     * isIdentifierPart.
-//     */
-//    static public boolean isIdentifier(String str) {
-//        int len = str.length();
-//        if (len == 0) {
-//            return false;
-//        } else if (! isIdentifierStart(str.charAt(0))) {
-//            return false;
-//        } else {
-//            for (int i = 1; i < len; i++) {
-//                if (! isIdentifierPart(str.charAt(i))) {
-//                    return false;
-//                }
-//            }
-//            //if it's not a keyword, it's an identifier
-//            return -1 == EParser.tokenType(str.toLowerCase());
-//        }
-//    }
-
-    /**
-     *
-     */
-    private AstroToken numberLiteral()
-      throws IOException, SyntaxException {
-        // Now handles floating point numbers as well as integers
-        boolean floating = false;
-        int radix = 10;
-        if (myChar == '0') {
-            radix = 8;
-            nextChar();
-            if (myChar == 'x' || myChar == 'X') {
-                radix = 16;
-                nextChar();
-            }
-        }
-        if (radix == 16) {
-            while (eatDigit(16)) {
-            }
-        } else {
-            //even if radix == 8, we may instead have a floating point literal
-            while (eatDigit(10)) {
-            }
-            // If we have a decimal point go for the fractional part
-            if (myChar == '.' && !peekChar('.')) {
-                nextChar();
-                floating = true;
-                while (eatDigit(10)) {
-                }
-            }
-
-            if ((myChar == 'E') || (myChar == 'e')) {
-                nextChar();
-                floating = true;
-                if (myChar == '-') {
-                    nextChar();
-                }
-                while (eatDigit(10)) {
-                }
-            }
-        }
-        Twine tok = endToken();
-        String str = tok.replaceAll("_", "").bare();
-        if (floating) {
-            return leafData(Double.valueOf(str), tok);
-        } else {
-            if (radix == 16) {
-                //remove the leading "0x" to make BigInteger happy
-                str = str.substring(2);
-            }
-            return leafData(new BigInteger(str, radix), tok);
-        }
-    }
-
-    /**
-     * XXX Get rid of peekChar/0 or make it work
-     */
-    private char peekChar() {
-        if (myChar == EOFCHAR || myChar == '\n') {
-            throw new Error("internal: can't peek here");
-        }
-        int last = myLData.length - 1;
-
-        if (myPos < last) {
-            return myLData[myPos + 1];
-        } else {
-            throw new Error("internal: (XXX bug) peek past end");
-        }
-    }
-
     /**
-     *
-     */
-    private boolean peekChar(char c) {
-        if (myChar == EOFCHAR || myChar == '\n') {
-            throw new Error("internal: can't peek here");
-        }
-        int last = myLData.length - 1;
-
-        if (myPos < last) {
-            return c == myLData[myPos + 1];
-        } else {
-            return false;
-        }
-    }
-
-    /**
      * XXX In order to enable optValue to be recovered from ttype and
      * source, we need four ttypes rather than the current two: QuasiOpen
      * and QuasiClose.
@@ -1223,83 +657,6 @@
                 );
             }
         }
-    }
-
-    /**
-     * Skip to the rest of this line.
-     */
-    private void skipLine() throws IOException {
-        if (null != myLTwine) {
-            myPos = myLData.length - 1;
-            myChar = myLData[myPos];
-        }
-        myDelayedNextChar = true;
-    }
-
-    /**
-     *
-     */
-    private void startToken() {
-        if (-1 != myOptStartPos || null != myOptStartText) {
-            throw new Error("internal: token already started");
-        }
-        myOptStartPos = myPos;
-    }
-
-    /**
-     * Cancels a started token
-     */
-    private void stopToken() {
-        myOptStartPos = -1;
-        myOptStartText = null;
-    }
-
-    /**
-     *
-     */
-    private Twine endToken() {
-        Twine result;
-        int pos = myPos;
-        if (myDelayedNextChar) {
-            pos++;
-        }
-        if (-1 == myOptStartPos) {
-            if (null == myOptStartText) {
-                throw new Error("internal: no current token");
-            } else {
-                //started on previous line
-                result = myOptStartText;
-                if (null != myLTwine) {
-                    result = (Twine)result.add(myLTwine.run(0, pos));
-                }
-            }
-        } else {
-            //starts on this line
-            result = (Twine)myLTwine.run(myOptStartPos, pos);
-        }
-        stopToken();
-        return result;
-    }
-
-    /**
-     *
-     */
-    private AstroToken stringLiteral() throws IOException, SyntaxException {
-        nextChar();
-        Twine openner = (Twine)myLTwine.run(myOptStartPos, myPos);
-        myIndenter.push(openner, '"', 0);
-        StringBuffer value = new StringBuffer();
-        while (myChar != '"') {
-            if (myChar == EOFCHAR) {
-                needMore("File ends inside string literal");
-            }
-            value.append(charConstant());
-            nextChar();
-        }
-        nextChar();
-        Twine closer = endToken();
-        myIndenter.pop('"', closer);
-        return leafData(value.toString(), closer);
     }
 
     /**



1.106     +2714 -3418e/src/jsrc/org/erights/e/elang/syntax/EParser.java

Index: EParser.java
===================================================================
RCS file: /cvs/e/src/jsrc/org/erights/e/elang/syntax/EParser.java,v
retrieving revision 1.105
retrieving revision 1.106
diff -u -r1.105 -r1.106
--- EParser.java	2001/12/02 06:01:44	1.105
+++ EParser.java	2001/12/02 18:42:01	1.106
@@ -23,3580 +23,2876 @@
 import org.erights.e.elib.tables.IdentityCacheTable;
 import org.erights.e.elib.tables.IntTable;
 import org.erights.e.elib.tables.Twine;
+import org.quasiliteral.astro.AstroSchema;
 import org.quasiliteral.astro.AstroToken;
+import org.quasiliteral.astro.BaseSchema;
+import org.quasiliteral.syntax.SyntaxException;
 
 import java.io.IOException;
 import java.io.InputStream;
 import java.io.ObjectInput;
 import java.io.ObjectInputStream;
+//#line 33 "EParser.java"
 
-//#line 30 "EParser.java"
 
 
+
 //#####################################################################
 // class: EParser
 // does : encapsulates yacc() parser functionality in a Java
 //        class for quick code development
 //#####################################################################
-public class EParser extends EBuilder {
-
-    boolean yydebug;        //do I want debug output?
-
-    int yynerrs;            //number of errors so far
+public class EParser extends EBuilder
+{
 
-    int yyerrflag;          //was there an error?
+boolean yydebug;        //do I want debug output?
+int yynerrs;            //number of errors so far
+int yyerrflag;          //was there an error?
+int yychar;             //the current working character
 
-    int yychar;             //the current working character
-
-    //########## MESSAGES ##########
+//########## MESSAGES ##########
 //###############################################################
 // method: debug
 //###############################################################
-    void debug(String msg) {
-        if (yydebug)
-            System.out.println(msg);
-    }
-
-    //########## STATE STACK ##########
-    final static int YYSTACKSIZE = 500;  //maximum stack size
-
-    int statestk[],stateptr;             //state stack
+void debug(String msg)
+{
+  if (yydebug)
+    System.out.println(msg);
+}
 
-    //###############################################################
+//########## STATE STACK ##########
+final static int YYSTACKSIZE = 500;  //maximum stack size
+int statestk[],stateptr;             //state stack
+//###############################################################
 // methods: state stack push,pop,drop,peek
 //###############################################################
-    void state_push(int state) {
-        if (stateptr >= YYSTACKSIZE)         //overflowed?
-            return;
-        statestk[++stateptr] = state;
-    }
-
-    int state_pop() {
-        if (stateptr < 0)                    //underflowed?
-            return -1;
-        return statestk[stateptr--];
-    }
-
-    void state_drop(int cnt) {
-        int ptr;
-        ptr = stateptr - cnt;
-        if (ptr < 0)
-            return;
-        stateptr = ptr;
-    }
-
-    int state_peek(int relative) {
-        int ptr;
-        ptr = stateptr - relative;
-        if (ptr < 0)
-            return -1;
-        return statestk[ptr];
-    }
-
-    //###############################################################
+void state_push(int state)
+{
+  if (stateptr>=YYSTACKSIZE)         //overflowed?
+    return;
+  statestk[++stateptr]=state;
+}
+int state_pop()
+{
+  if (stateptr<0)                    //underflowed?
+    return -1;
+  return statestk[stateptr--];
+}
+void state_drop(int cnt)
+{
+int ptr;
+  ptr=stateptr-cnt;
+  if (ptr<0)
+    return;
+  stateptr = ptr;
+}
+int state_peek(int relative)
+{
+int ptr;
+  ptr=stateptr-relative;
+  if (ptr<0)
+    return -1;
+  return statestk[ptr];
+}
+//###############################################################
 // method: init_stacks : allocate and prepare stacks
 //###############################################################
-    boolean init_stacks() {
-        statestk = new int[YYSTACKSIZE];
-        stateptr = -1;
-        val_init();
-        return true;
-    }
-
-    //###############################################################
+boolean init_stacks()
+{
+  statestk = new int[YYSTACKSIZE];
+  stateptr = -1;
+  val_init();
+  return true;
+}
+//###############################################################
 // method: dump_stacks : show n levels of the stacks
 //###############################################################
-    void dump_stacks(int count) {
-        int i;
-        System.out.println("=index==state====value=     s:" + stateptr + "  v:" + valptr);
-        for (i = 0; i < count; i++)
-            System.out.println(" " + i + "    " + statestk[i] + "      " + valstk[i]);
-        System.out.println("======================");
-    }
+void dump_stacks(int count)
+{
+int i;
+  System.out.println("=index==state====value=     s:"+stateptr+"  v:"+valptr);
+  for (i=0;i<count;i++)
+    System.out.println(" "+i+"    "+statestk[i]+"      "+valstk[i]);
+  System.out.println("======================");
+}
 
 
-    //########## SEMANTIC VALUES ##########
+//########## SEMANTIC VALUES ##########
 //## **user defined:Object
-    String yytext;//user variable to return contextual strings
-
-    Object yyval; //used to return semantic vals from action routines
-
-    Object yylval;//the 'lval' (result) I got from yylex()
-
-    Object valstk[];
-
-    int valptr;
-
-    //###############################################################
+String   yytext;//user variable to return contextual strings
+Object yyval; //used to return semantic vals from action routines
+Object yylval;//the 'lval' (result) I got from yylex()
+Object valstk[];
+int valptr;
+//###############################################################
 // methods: value stack push,pop,drop,peek.
 //###############################################################
-    void val_init() {
-        valstk = new Object[YYSTACKSIZE];
-        yyval = new Object();
-        yylval = new Object();
-        valptr = -1;
-    }
-
-    void val_push(Object val) {
-        if (valptr >= YYSTACKSIZE)
-            return;
-        valstk[++valptr] = val;
-    }
-
-    Object val_pop() {
-        if (valptr < 0)
-            return null;
-        return valstk[valptr--];
-    }
-
-    void val_drop(int cnt) {
-        int ptr;
-        ptr = valptr - cnt;
-        if (ptr < 0)
-            return;
-        valptr = ptr;
-    }
-
-    Object val_peek(int relative) {
-        int ptr;
-        ptr = valptr - relative;
-        if (ptr < 0)
-            return null;
-        return valstk[ptr];
-    }
-
-    //#### end semantic value section ####
-    public final static short LiteralInteger = 257;
-
-    public final static short LiteralFloat64 = 258;
-
-    public final static short LiteralChar = 259;
-
-    public final static short LiteralString = 260;
-
-    public final static short LiteralTwine = 261;
-
-    public final static short ID = 262;
-
-    public final static short VerbAssign = 263;
-
-    public final static short QuasiOpen = 264;
-
-    public final static short QuasiClose = 265;
-
-    public final static short DollarIdent = 266;
-
-    public final static short AtIdent = 267;
-
-    public final static short DollarOpen = 268;
-
-    public final static short AtOpen = 269;
-
-    public final static short URI = 270;
-
-    public final static short URIStart = 271;
-
-    public final static short BodyStartWord = 272;
-
-    public final static short BodyNextWord = 273;
-
-    public final static short VTableStartWord = 274;
-
-    public final static short VTableNextWord = 275;
-
-    public final static short BIND = 276;
-
-    public final static short CATCH = 277;
-
-    public final static short CLASS = 278;
-
-    public final static short DEF = 279;
-
-    public final static short DELEGATE = 280;
-
-    public final static short ELSE = 281;
-
-    public final static short ESCAPE = 282;
-
-    public final static short FINALLY = 283;
-
-    public final static short FOR = 284;
-
-    public final static short IF = 285;
-
-    public final static short IN = 286;
-
-    public final static short MATCH = 287;
-
-    public final static short META = 288;
-
-    public final static short PRAGMA = 289;
-
-    public final static short SWITCH = 290;
-
-    public final static short THUNK = 291;
-
-    public final static short TO = 292;
-
-    public final static short TRY = 293;
-
-    public final static short VAR = 294;
-
-    public final static short WHEN = 295;
-
-    public final static short WHILE = 296;
-
-    public final static short _ = 297;
-
-    public final static short DEFINE = 298;
-
-    public final static short ON = 299;
-
-    public final static short SELECT = 300;
-
-    public final static short TYPEDEF = 301;
-
-    public final static short ABSTRACT = 302;
-
-    public final static short AN = 303;
-
-    public final static short AS = 304;
-
-    public final static short ATTRIBUTE = 305;
-
-    public final static short BE = 306;
-
-    public final static short BEGIN = 307;
-
-    public final static short BEHALF = 308;
-
-    public final static short BELIEF = 309;
-
-    public final static short BELIEVE = 310;
-
-    public final static short BELIEVES = 311;
-
-    public final static short CASE = 312;
-
-    public final static short CONST = 313;
-
-    public final static short CONSTRUCTOR = 314;
-
-    public final static short CONTEXT = 315;
-
-    public final static short DECLARE = 316;
-
-    public final static short DEFAULT = 317;
-
-    public final static short DEFMACRO = 318;
-
-    public final static short DEPRECATED = 319;
-
-    public final static short DISPATCH = 320;
-
-    public final static short DO = 321;
-
-    public final static short ENCAPSULATE = 322;
-
-    public final static short ENCAPSULATED = 323;
-
-    public final static short ENCAPSULATES = 324;
-
-    public final static short END = 325;
-
-    public final static short ENSURE = 326;
-
-    public final static short ENUM = 327;
-
-    public final static short EVENTUAL = 328;
-
-    public final static short EVENTUALLY = 329;
-
-    public final static short EXPORT = 330;
-
-    public final static short EXTENDS = 331;
-
-    public final static short FACET = 332;
-
-    public final static short FORALL = 333;
-
-    public final static short FUNCTION = 334;
-
-    public final static short GIVEN = 335;
-
-    public final static short HIDDEN = 336;
-
-    public final static short HIDES = 337;
-
-    public final static short IMPLEMENTS = 338;
-
-    public final static short INTERFACE = 339;
-
-    public final static short IS = 340;
-
-    public final static short KNOW = 341;
-
-    public final static short KNOWS = 342;
-
-    public final static short LAMBDA = 343;
-
-    public final static short LET = 344;
-
-    public final static short METHOD = 345;
-
-    public final static short METHODS = 346;
-
-    public final static short MODULE = 347;
-
-    public final static short NAMESPACE = 348;
-
-    public final static short NATIVE = 349;
-
-    public final static short OBEYS = 350;
-
-    public final static short OCTET = 351;
-
-    public final static short ONEWAY = 352;
-
-    public final static short PACKAGE = 353;
-
-    public final static short PRIVATE = 354;
-
-    public final static short PROTECTED = 355;
-
-    public final static short PUBLIC = 356;
-
-    public final static short RAISES = 357;
-
-    public final static short RELIANCE = 358;
-
-    public final static short RELIANT = 359;
-
-    public final static short RELIES = 360;
-
-    public final static short RELY = 361;
-
-    public final static short REVEAL = 362;
-
-    public final static short SAKE = 363;
-
-    public final static short SIGNED = 364;
-
-    public final static short STATIC = 365;
-
-    public final static short STRUCT = 366;
-
-    public final static short SUCHTHAT = 367;
-
-    public final static short SUPPORTS = 368;
-
-    public final static short SUSPECT = 369;
-
-    public final static short SUSPECTS = 370;
-
-    public final static short SYNCHRONIZED = 371;
-
-    public final static short THIS = 372;
-
-    public final static short THROWS = 373;
-
-    public final static short TRANSIENT = 374;
-
-    public final static short TRUNCATABLE = 375;
-
-    public final static short UNSIGNED = 376;
-
-    public final static short UNUM = 377;
-
-    public final static short USES = 378;
-
-    public final static short USING = 379;
-
-    public final static short UTF8 = 380;
-
-    public final static short UTF16 = 381;
-
-    public final static short VALUETYPE = 382;
-
-    public final static short VIRTUAL = 383;
-
-    public final static short VOLATILE = 384;
-
-    public final static short WSTRING = 385;
-
-    public final static short EOL = 386;
-
-    public final static short OpLAnd = 387;
-
-    public final static short OpLOr = 388;
-
-    public final static short OpSame = 389;
-
-    public final static short OpNSame = 390;
-
-    public final static short OpButNot = 391;
-
-    public final static short OpLeq = 392;
-
-    public final static short OpABA = 393;
-
-    public final static short OpGeq = 394;
-
-    public final static short OpThru = 395;
-
-    public final static short OpTill = 396;
-
-    public final static short OpAsl = 397;
-
-    public final static short OpAsr = 398;
-
-    public final static short OpFlrDiv = 399;
-
-    public final static short OpMod = 400;
-
-    public final static short OpPow = 401;
-
-    public final static short OpAss = 402;
-
-    public final static short OpAssAdd = 403;
-
-    public final static short OpAssAnd = 404;
-
-    public final static short OpAssAprxDiv = 405;
-
-    public final static short OpAssFlrDiv = 406;
-
-    public final static short OpAssAsl = 407;
-
-    public final static short OpAssAsr = 408;
-
-    public final static short OpAssRemdr = 409;
-
-    public final static short OpAssMod = 410;
-
-    public final static short OpAssMul = 411;
-
-    public final static short OpAssOr = 412;
-
-    public final static short OpAssPow = 413;
-
-    public final static short OpAssSub = 414;
-
-    public final static short OpAssXor = 415;
-
-    public final static short Send = 416;
-
-    public final static short OpWhen = 417;
-
-    public final static short MapsTo = 418;
-
-    public final static short MatchBind = 419;
-
-    public final static short MisMatch = 420;
-
-    public final static short Audit = 421;
-
-    public final static short YYERRCODE = 256;
-
-    final static short yylhs[] = {                           -1,
-                                                             0,    0,    0,    4,    4,    2,    6,    5,    5,    7,
-                                                             7,    8,   10,   10,   11,   11,   11,   14,   14,   12,
-                                                             12,   12,   12,   12,   12,   12,   12,   16,   16,   21,
-                                                             21,   22,   22,   22,   22,   22,   22,   22,   22,   22,
-                                                             24,   24,   23,   23,   23,   23,   23,   23,   25,   25,
-                                                             25,   26,   26,   26,   28,   28,   27,   27,   27,   30,
-                                                             30,   29,   29,   29,   29,   29,   29,   32,   32,   31,
-                                                             31,   34,   34,   33,   33,   33,   33,   33,   35,   35,
-                                                             35,   35,   35,   35,   35,   35,   35,   38,   38,   38,
-                                                             38,   38,   38,   37,   37,   37,   36,   36,   36,   36,
-                                                             36,   36,   36,   36,   36,   36,   36,   36,   36,   36,
-                                                             36,   36,   36,   36,   36,   36,   36,   36,   36,   36,
-                                                             36,   36,   36,   36,   36,   59,   59,   59,   59,   59,
-                                                             59,   43,   46,   56,   56,   56,   54,   55,   57,   57,
-                                                             69,   68,   68,   67,   67,   67,   44,   44,   44,   45,
-                                                             45,   70,   70,   71,   71,   72,   72,   74,   74,   75,
-                                                             76,   76,   64,   64,   77,   77,    3,    3,    3,   79,
-                                                             79,   79,   79,   79,   80,   80,   81,   81,   82,   82,
-                                                             83,   83,   84,   84,   85,   85,   78,   78,   78,   78,
-                                                             78,   78,   78,   78,   78,   19,   19,   20,   20,   86,
-                                                             86,   86,   86,   86,   86,   86,   88,   88,   88,   89,
-                                                             89,   60,   60,   90,   90,   15,   15,   87,   87,   92,
-                                                             92,   92,   92,   92,   93,   93,   93,   62,   62,   62,
-                                                             63,   95,   96,   94,   94,   97,   65,   65,   98,   98,
-                                                             99,    1,    1,    9,    9,  100,   73,   18,   18,   39,
-                                                             39,   91,   91,   47,   47,  101,  101,   40,   13,   41,
-                                                             41,   17,   17,   17,   17,   17,   17,   17,   17,   17,
-                                                             17,   17,   17,   49,   49,   50,   61,   61,   61,  104,
-                                                             104,  105,  105,  103,  103,   52,   52,   66,  106,   53,
-                                                             53,   58,   58,  107,  107,  107,  107,  109,  109,  109,
-                                                             109,  108,  108,  108,  111,  111,  112,  112,  113,  113,
-                                                             110,  110,   42,   42,   48,   51,  102,  102,  102,  102,
-                                                             102,  102,  102,  102,  102,  102,  102,  102,  102,  102,
-                                                             102,  102,  102,  102,  102,  102,  102,  102,  102,  102,
-                                                             102,  102,  102,  102,  102,  102,  102,  102,  102,  102,
-                                                             102,  102,  102,  102,  102,  102,  102,  102,  102,  102,
-                                                             102,  102,  102,  102,  102,  102,  102,  102,  102,  102,
-                                                             102,  102,  102,  102,  102,  102,  102,  102,  102,  102,
-                                                             102,  102,  102,  102,  102,  102,  102,  102,  102,  102,
-                                                             102,  102,  102,  102,  102,  102,  102,  102,  102,  102,
-    };
-
-    final static short yylen[] = {                            2,
-                                                              1,    1,    2,    1,    1,    3,    3,    1,    3,    1,
-                                                              3,    1,    1,    2,    1,    3,    2,    1,    1,    1,
-                                                              3,    3,    3,    3,    4,    3,    3,    1,    3,    1,
-                                                              3,    1,    3,    3,    3,    3,    3,    3,    3,    3,
-                                                              1,    1,    1,    3,    3,    3,    3,    3,    1,    3,
-                                                              3,    1,    3,    3,    1,    1,    1,    3,    3,    1,
-                                                              1,    1,    3,    3,    3,    3,    3,    1,    1,    1,
-                                                              3,    1,    1,    1,    2,    2,    2,    2,    1,    1,
-                                                              4,    4,    3,    3,    2,    3,    4,    2,    3,    3,
-                                                              4,    2,    3,    1,    2,    3,    1,    1,    1,    1,
-                                                              1,    1,    1,    3,    2,    1,    3,    3,    2,    4,
-                                                              4,    5,    5,    1,    1,    1,    1,    3,    2,    2,
-                                                              3,    2,    3,    2,    1,    2,    4,    3,    3,    4,
-                                                              3,    1,    3,    4,    6,    7,    8,    5,    5,    6,
-                                                              0,    6,    6,    0,    1,    1,    0,    1,    3,    1,
-                                                              2,    2,    3,    1,    3,    1,    2,    1,    4,    2,
-                                                              1,    4,    1,    1,    3,    2,    1,    3,    4,    1,
-                                                              3,    5,    3,    5,    1,    2,    1,    2,    1,    2,
-                                                              2,    3,    1,    1,    1,    3,    3,    1,    2,    1,
-                                                              3,    1,    1,    3,    3,    4,    2,    4,    2,    1,
-                                                              1,    2,    2,    3,    3,    1,    2,    2,    2,    1,
-                                                              3,    1,    3,    1,    4,    2,    5,    1,    1,    4,
-                                                              6,    4,    6,    4,    4,    5,    2,    4,    5,    2,
-                                                              6,    4,    3,    0,    2,    3,    8,    6,    1,    3,
-                                                              3,    0,    1,    1,    2,    0,    1,    3,    2,    1,
-                                                              1,    1,    3,    1,    3,    3,    2,    1,    1,    1,
-                                                              1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-                                                              1,    1,    1,    4,    6,    4,    5,    1,    1,    1,
-                                                              3,    1,    3,    1,    3,    1,    1,    2,    4,    0,
-                                                              3,    5,    3,    1,    2,    2,    4,    2,    4,    2,
-                                                              4,    2,    5,    4,    2,    3,    1,    4,    2,    2,
-                                                              0,    2,    1,    1,    0,    0,    1,    1,    1,    1,
-                                                              1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-                                                              1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-                                                              1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-                                                              1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-                                                              1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-                                                              1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-                                                              1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-                                                              1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-    };
-
-    final static short yydefred[] = {                         0,
-                                                              244,    0,    0,    0,    2,    0,  260,    0,    0,    0,
-                                                              313,  314,    0,    0,  317,  318,  319,  320,  321,  322,
-                                                              323,  324,  325,  326,  327,  328,  329,  330,  331,  332,
-                                                              333,  334,  335,  336,  337,  338,  339,  340,  341,  342,
-                                                              343,  344,  345,  346,  347,  348,  349,  350,  351,  352,
-                                                              353,  354,  355,  356,  357,  358,  359,  360,  361,  362,
-                                                              363,  364,  365,  366,  367,  368,  369,  370,  371,  372,
-                                                              373,  374,  375,  376,  377,  378,  379,  380,  381,  382,
-                                                              383,  384,  385,  386,  387,  388,  389,  390,  391,  392,
-                                                              393,  394,  395,  396,  397,  398,  399,  400,    0,    0,
-                                                              0,    0,    3,    0,  192,  193,    0,    0,    0,  177,
-                                                              0,  170,  175,  261,   97,   98,   99,  100,  101,    0,
-                                                              0,  103,    0,  315,  315,    0,    0,    4,    0,    0,
-                                                              5,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                              0,    0,    0,    8,   12,    0,   15,  132,    0,    0,
-                                                              0,    0,   30,    0,    0,    0,    0,    0,   62,    0,
-                                                              0,   94,    0,   80,    0,  102,    0,  106,    0,  114,
-                                                              115,  116,  117,  125,    0,    0,  245,    0,    0,    0,
-                                                              259,    0,    0,    0,    0,    0,  176,  189,    0,  247,
-                                                              0,    0,  156,    0,    0,    0,  161,    0,    0,    0,
-                                                              0,    0,    0,  179,  178,    0,    0,    0,    0,    0,
-                                                              0,    0,    0,  218,  219,    0,    0,    0,    0,  201,
-                                                              200,    0,    0,  206,  315,    0,    0,    0,  315,    0,
-                                                              0,  124,    0,   78,   77,   75,   76,    0,    0,    0,
-                                                              0,    0,  250,    0,  254,  119,  120,  122,    0,    0,
-                                                              0,    0,    0,    0,    0,    0,  207,    6,    0,    0,
-                                                              0,    0,    0,  262,  263,  264,  265,  266,    0,  267,
-                                                              268,  269,  270,  271,  272,  273,    0,    0,    0,    0,
-                                                              0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                              0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                              0,    0,    0,    0,    0,    0,    0,    0,    0,  258,
-                                                              0,    0,    0,    0,    0,    0,  150,  105,    0,    0,
-                                                              0,    0,    0,    0,    0,    0,    0,    0,  109,    0,
-                                                              0,  126,  278,  279,    0,  194,  195,    0,    0,  191,
-                                                              208,  209,  166,    0,    0,    0,  157,    0,    0,  160,
-                                                              0,   10,  149,  187,    0,    0,  154,  185,    0,    0,
-                                                              183,  181,  184,    0,  180,  168,  118,  121,  104,  146,
-                                                              145,    0,    0,    0,    0,  202,  203,  129,    0,    0,
-                                                              252,    0,  246,    0,    0,    0,  123,    0,    0,    0,
-                                                              0,  257,    0,  107,  108,    0,    0,    0,    0,    0,
-                                                              0,    0,    0,    9,    0,   16,    0,    0,   21,   23,
-                                                              0,   18,   22,   19,   26,   27,   31,   33,   34,   42,
-                                                              41,   38,   39,   40,   35,   36,   37,   45,   46,   47,
-                                                              44,   48,    0,    0,   56,    0,   53,    0,   61,    0,
-                                                              58,   59,   69,   68,   65,   67,   63,   64,   66,   73,
-                                                              72,   71,    0,    0,    0,    0,    0,    0,    0,  249,
-                                                              0,    0,    0,  152,    0,  151,    0,    0,    0,  164,
-                                                              0,    0,  128,  246,    0,    0,    0,  131,    0,    0,
-                                                              246,    0,    0,    0,  214,    0,  196,  198,  165,    0,
-                                                              0,    0,    0,    7,    0,  133,  169,    0,    0,  182,
-                                                              0,    0,  316,  204,  205,    0,    0,  236,  315,    0,
-                                                              286,    0,  315,  246,    0,    0,    0,    0,    0,  302,
-                                                              293,  256,    0,  255,  253,    0,    0,   25,    0,  216,
-                                                              0,    0,   81,    0,  248,    0,  153,  110,    0,    0,
-                                                              316,    0,  287,  111,  158,    0,    0,    0,  230,  130,
-                                                              316,    0,  280,    0,  233,    0,  127,    0,  172,  159,
-                                                              174,    0,  162,   11,  155,  186,  315,  139,    0,    0,
-                                                              0,    0,  288,    0,  138,    0,    0,  239,    0,  284,
-                                                              0,    0,    0,  305,    0,  307,    0,    0,    0,    0,
-                                                              294,    0,    0,    0,  312,    0,  315,  315,  112,    0,
-                                                              113,    0,    0,  235,  274,    0,    0,    0,    0,    0,
-                                                              232,    0,    0,  315,  140,    0,    0,    0,    0,    0,
-                                                              0,    0,  276,    0,    0,  310,  309,    0,  306,  304,
-                                                              295,  298,  300,  292,  296,    0,    0,    0,    0,    0,
-                                                              135,  228,    0,  316,    0,    0,    0,  281,    0,  277,
-                                                              215,    0,    0,  231,    0,  291,  241,  238,  240,    0,
-                                                              285,    0,    0,    0,    0,  303,  217,  316,  136,  229,
-                                                              275,    0,    0,    0,    0,    0,    0,  283,  316,    0,
-                                                              289,    0,  308,  297,  299,  301,  137,    0,  224,    0,
-                                                              0,    0,  227,  220,  222,    0,    0,  237,  316,    0,
-                                                              316,    0,  143,  142,  223,  225,  221,    0,  226,
-    };
-
-    final static short yydgoto[] = {                          3,
-                                                              198,    5,  545,  186,  143,  381,  351,  144,    6,  352,
-                                                              146,  147,  148,  413,  443,  149,  277,  312,  105,  106,
-                                                              152,  153,  154,  422,  155,  156,  157,  437,  158,  441,
-                                                              159,  445,  160,  452,  161,  162,  163,  164,  241,  390,
-                                                              107,  165,  166,  167,  318,  168,  242,  169,  329,  387,
-                                                              570,  509,  575,  170,  171,  172,  173,  232,  174,  175,
-                                                              332,  479,  222,  469,  228,  510,  372,  568,  569,  319,
-                                                              361,  192,  193,  194,  195,  196,  197,  110,  111,  112,
-                                                              113,  205,  206,  362,  363,  223,  224,  176,  225,  486,
-                                                              244,  608,  675,  693,  333,  334,  230,  577,  578,  511,
-                                                              245,  114,  581,  554,  610,  573,  592,  391,  593,  520,
-                                                              516,  585,  586,
-    };
-
-    final static short yysindex[] = {                      -310,
-                                                           0,15951,    0,14168,    0, -280,    0, -127, -122,19458,
-                                                           0,    0,19458,   87,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,    0,    0,    0,    0,    0,    0,16556,19458,
-                                                           12002, -229,    0,  104,    0,    0,    0,  163,  -95,    0,
-                                                           142,    0,    0,    0,    0,    0,    0,    0,    0,  -44,
-                                                           6,    0,14521,    0,    0,19458,19086,    0,19458,16806,
-                                                           0,  163,19086,19458,16556,16556,16556, -306,   -9,    8,
-                                                           -229,15129, -229,    0,    0,  190,    0,    0,  735, -125,
-                                                           -109, -107,    0,  -24,   76,   66,   52,    2,    0,  -84,
-                                                           12592,    0,  265,    0,12252,    0,  -23,    0,  694,    0,
-                                                           0,    0,    0,    0,  197,  -93,    0,  201,  216,  285,
-                                                           0,  290,14521,19458,19458,19086,    0,    0,16680,    0,
-                                                           -48,  260,    0,  -27,  284,  -26,    0,14168,  332,14521,
-                                                           -229,  -40,  456,    0,    0,   46,14521,  255,  257,   49,
-                                                           16075,16075,  285,    0,    0,  127,  131,19458,19458,    0,
-                                                           0,  271,  -14,    0,    0,  290, -229,  271,    0,  -20,
-                                                           289,    0,17870,    0,    0,    0,    0,19458,14168,   -5,
-                                                           323,   17,    0,  373,    0,    0,    0,    0,  379,  164,
-                                                           176,19458,19458,   87,   32,  104,    0,    0,12721,14168,
-                                                           265,14521,14168,    0,    0,    0,    0,    0,14168,    0,
-                                                           0,    0,    0,    0,    0,    0,14650,14168,14168,14521,
-                                                           14521,14521,15003,15951,15951,15003,15003,15003,14521,14521,
-                                                           14521,14521,14521,14521,14521,15003,14521,15003,15003,15003,
-                                                           15003,15003,15003,15003,15003,18588, -229,19458,  265,    0,
-                                                           -229,  147,18588,  147,  265, -152,    0,    0,   58,15951,
-                                                           12127,  163,  163,  271,  271,  163,17994, -229,    0, -229,
-                                                           17400,    0,    0,    0,19458,    0,    0,14521,14521,    0,
-                                                           0,    0,    0,15951,  396, -229,    0,  325, -229,    0,
-                                                           -229,    0,    0,    0,  409,15951,    0,    0, -229,15951,
-                                                           0,    0,    0,  456,    0,    0,    0,    0,    0,    0,
-                                                           0,  271,  197,  327,  333,    0,    0,    0,19458,  419,
-                                                           0,   40,    0,  431,19086, -229,    0, -229, -229,   61,
-                                                           86,    0, -229,    0,    0, -306, -229,    0,  348,  350,
-                                                           285,  290,14168,    0,15129,    0,  147, -107,    0,    0,
-                                                           -12,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,  -96,  -96,    0,   52,    0,   52,    0,    2,
-                                                           0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,  147,  265,  383,  265,  147,  437, -126,    0,
-                                                           147,  265,  147,    0, -152,    0,  271,  -48,  193,    0,
-                                                           271,  289,    0,    0,  271,15601,   89,    0,  271,14039,
-                                                           0,  271,15951,  271,    0,  436,    0,    0,    0,16423,
-                                                           15951,16423,12127,    0,12721,    0,    0,  357,  358,    0,
-                                                           210, -112,    0,    0,    0,  436,15601,    0,    0,    0,
-                                                           0, -229,    0,    0,19210,  445, -184, -229,19458,    0,
-                                                           0,    0,   -5,    0,    0,    0,    0,    0,  104,    0,
-                                                           102,  147,    0,  147,    0,  147,    0,    0,14168,  206,
-                                                           0,    0,    0,    0,    0,  451,15601,14521,    0,    0,
-                                                           0, -229,    0,    0,    0,  271,    0, -229,    0,    0,
-                                                           0,  -48,    0,    0,    0,    0,    0,    0,  220,  210,
-                                                           455,  221,    0,  214,    0,   90,  179,    0,  463,    0,
-                                                           381,  446,  446,    0,  -10,    0,  446, -229,18712,18712,
-                                                           0,  390, -229,  477,    0, -229,    0,    0,    0, -103,
-                                                           0,  462,  480,    0,    0,  397, -133, -229,    0,  400,
-                                                           0,19458,16075,    0,    0,  462,15951,  271,15951,  462,
-                                                           -229,15951,    0,  242, -229,    0,    0, -229,    0,    0,
-                                                           0,    0,    0,    0,    0, -213,  446,  213,  271,  -64,
-                                                           0,    0,  462,    0,  163,18836,18836,    0, -229,    0,
-                                                           0,  197,16075,    0,  271,    0,    0,    0,    0,  230,
-                                                           0,19210, -229,18712,18712,    0,    0,    0,    0,    0,
-                                                           0, -111,15601,  -30,  271,  114,  271,    0,    0,  271,
-                                                           0,  462,    0,    0,    0,    0,    0,  163,    0,  489,
-                                                           14168,15601,    0,    0,    0,  210,  210,    0,    0,  462,
-                                                           0,  497,    0,    0,    0,    0,    0,  462,    0,
-    };
-
-    final static short yyrindex[] = {                      9616,
-                                                           0,   81,    0,  645,    0, 8526,    0,    0,    0,    0,
-                                                           0,    0,    0, 8650,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,    0,    0,    0,    0,    0,    0,  821,    0,
-                                                           20,13686,    0, 8916,    0,    0,  969,    0,    0,    0,
-                                                           9219,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,  821,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,    0,    0,  821,  821,  821,13075,    0,    0,
-                                                           13686,   81,  540,    0,    0,   25,    0,    0,  779,    0,
-                                                           0, 9416,    0, 9379, 8346, 7962, 7503, 7330,    0, 7291,
-                                                           6907,    0, 5168,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,    0,    0,17524,17152,    0,    0,    0, 8951,
-                                                           0, 8984,  821,    0,    0,    0,    0,    0,    0,    0,
-                                                           -35,    0,    0,   30,    0,  449,    0,  821,    0,  821,
-                                                           13686,    0,    0,    0,    0,    0,  821,    0,    0,    0,
-                                                           -88,  -86,11183,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,18340,    0,    0,11529,13686,    0,    0,    0,
-                                                           0,    0,    0,    0,    0,    0,    0,    0,  661,   29,
-                                                           0,    0,    0,   33,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,    0, 9773,    0, 1135,    0,    0,  791,  391,
-                                                           0,  821,  821,    0,    0,    0,    0,    0,  821,    0,
-                                                           0,    0,    0,    0,    0,    0,  821,  821,  821,  821,
-                                                           821,  821,  821,   81,   81,  821,  821,  821,  821,  821,
-                                                           821,  821,  821,  821,  821,  821,  821,  821,  821,  821,
-                                                           821,  821,  821,  821,  821,    0,13075,    0, 5589,    0,
-                                                           13204, 1522,    0, 2848, 5748,    0,    0,    0,    0,   81,
-                                                           81,    0,    0,    0,    0,    0,    0,13557,    0,  -80,
-                                                           0,    0,    0,    0,    0,    0,    0,  821,  821,    0,
-                                                           0,    0,    0,   81, 9142,15477,    0, 9182,11654,    0,
-                                                           -8,    0,    0,    0,    0,   81,    0,    0,13686,   81,
-                                                           0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,  -94,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,    0,    0,    0,  -60,    0,18960,  -37, -105,
-                                                           0,    0,13686,    0,    0,13686,13686, 1681,    0,    0,
-                                                           10119,10243,  821,    0,   81,    0,  746, 9449,    0,    0,
-                                                           13686,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0, 8193, 8269,    0, 7809,    0, 7886,    0, 7367,
-                                                           0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0, 3269, 6169,    0, 6328, 2102,    0,    0,    0,
-                                                           3428, 6749, 3849,    0,    0,    0,    0,  261,    0,    0,
-                                                           0,    0,    0,    0,    0,    5,  423,    0,    0,  821,
-                                                           0,    0,   81,    0,    0,17276,    0,    0,    0,   81,
-                                                           81,   81,   81,    0,  -18,    0,    0,    0,    0,    0,
-                                                           276,    0,    0,    0,    0,18464,    5,    0,    0, 2261,
-                                                           0,13686,    0,    0,  511,    0,  426,18960,    0,    0,
-                                                           0,    0,    0,    0,    0,10589,10713,    0,11059,    0,
-                                                           0, 4008,    0, 4429,    0, 4588,    0,    0,  821, 5009,
-                                                           0, 2682,    0,    0,    0,    0,    5,  821,    0,    0,
-                                                           0,  429,    0,  280,    0,    0,    0,19582,    0,    0,
-                                                           0,    0,    0,    0,    0,    0,    0,    0,    0,  276,
-                                                           0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                           270,    7,    7,    0,  517,    0, -105,  429,    0,    0,
-                                                           0,    0,  429,    0,    0,13686,    0,    0,    0,    0,
-                                                           0,  423,    0,    0,    0,    0,    0,  -80,  -69,    0,
-                                                           0,    0,  -86,    0,    0,  423,   81,    0,   81,  423,
-                                                           13686,   81,    0,    0,  -65,    0,    0,19334,    0,    0,
-                                                           0,    0,    0,    0,    0,  440, -105,    0,    0,    0,
-                                                           0,    0,  423,    0,    0,    0,    0,    0,  429,    0,
-                                                           0,  -94,  -88,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,  429,    0,    0,    0,    0,    0,    0,    0,
-                                                           0,    0,    5,  423,    0,  423,    0,    0,    0,    0,
-                                                           0,  423,    0,    0,    0,    0,    0,    0,    0,    0,
-                                                           821,    5,    0,    0,    0,  276,  276,    0,    0,  423,
-                                                           0,    0,    0,    0,    0,    0,    0,  423,    0,
-    };
-
-    final static short yygindex[] = {                         0,
-                                                              1,    0,  243,   37,    0,  -98,   91,  302, -137,   -1,
-                                                              0, -247,   -2,    0,  903,    0,    0,  295,  159,  188,
-                                                              307,  293,  -49,  143,   45,   67,  -71,    0,   57,  275,
-                                                              233,  457,  272,    0,    0,  -46,    0,    0,  -67, -146,
-                                                              580,   48, -231,   19,    0,  -70,    0,  510,  322,   98,
-                                                              51,  106,   36,    0,    0,  -17,    0,    0,  310,    0,
-                                                              -331,  251,    0,    0,    0,  110, -207, -498,    0,    0,
-                                                              -269, -343,  -83,  -34,    0,    0, -257,  407, -301,    0,
-                                                              0,    0,    0,  234,    0, -118,    0,    0,  -76,  218,
-                                                              -225,    0,  -62, -414, -488,   -4,    0,    0,  -21, -190,
-                                                              211,    0,   59,    0,    0,    0,    0, -512,    0, -500,
-                                                              88,    0,  -50,
-    };
-
-    final static int YYTABLESIZE = 19967;
+void val_init()
+{
+  valstk=new Object[YYSTACKSIZE];
+  yyval=new Object();
+  yylval=new Object();
+  valptr=-1;
+}
+void val_push(Object val)
+{
+  if (valptr>=YYSTACKSIZE)
+    return;
+  valstk[++valptr]=val;
+}
+Object val_pop()
+{
+  if (valptr<0)
+    return null;
+  return valstk[valptr--];
+}
+void val_drop(int cnt)
+{
+int ptr;
+  ptr=valptr-cnt;
+  if (ptr<0)
+    return;
+  valptr = ptr;
+}
+Object val_peek(int relative)
+{
+int ptr;
+  ptr=valptr-relative;
+  if (ptr<0)
+    return null;
+  return valstk[ptr];
+}
+//#### end semantic value section ####
+public final static short LiteralInteger=257;
+public final static short LiteralFloat64=258;
+public final static short LiteralChar=259;
+public final static short LiteralString=260;
+public final static short LiteralTwine=261;
+public final static short ID=262;
+public final static short VerbAssign=263;
+public final static short QuasiOpen=264;
+public final static short QuasiClose=265;
+public final static short DollarIdent=266;
+public final static short AtIdent=267;
+public final static short DollarOpen=268;
+public final static short AtOpen=269;
+public final static short URI=270;
+public final static short URIStart=271;
+public final static short BodyStartWord=272;
+public final static short BodyNextWord=273;
+public final static short VTableStartWord=274;
+public final static short VTableNextWord=275;
+public final static short BIND=276;
+public final static short CATCH=277;
+public final static short CLASS=278;
+public final static short DEF=279;
+public final static short DELEGATE=280;
+public final static short ELSE=281;
+public final static short ESCAPE=282;
+public final static short FINALLY=283;
+public final static short FOR=284;
+public final static short IF=285;
+public final static short IN=286;
+public final static short MATCH=287;
+public final static short META=288;
+public final static short PRAGMA=289;
+public final static short SWITCH=290;
+public final static short THUNK=291;
+public final static short TO=292;
+public final static short TRY=293;
+public final static short VAR=294;
+public final static short WHEN=295;
+public final static short WHILE=296;
+public final static short _=297;
+public final static short DEFINE=298;
+public final static short ON=299;
+public final static short SELECT=300;
+public final static short TYPEDEF=301;
+public final static short ABSTRACT=302;
+public final static short AN=303;
+public final static short AS=304;
+public final static short ATTRIBUTE=305;
+public final static short BE=306;
+public final static short BEGIN=307;
+public final static short BEHALF=308;
+public final static short BELIEF=309;
+public final static short BELIEVE=310;
+public final static short BELIEVES=311;
+public final static short CASE=312;
+public final static short CONST=313;
+public final static short CONSTRUCTOR=314;
+public final static short CONTEXT=315;
+public final static short DECLARE=316;
+public final static short DEFAULT=317;
+public final static short DEFMACRO=318;
+public final static short DEPRECATED=319;
+public final static short DISPATCH=320;
+public final static short DO=321;
+public final static short ENCAPSULATE=322;
+public final static short ENCAPSULATED=323;
+public final static short ENCAPSULATES=324;
+public final static short END=325;
+public final static short ENSURE=326;
+public final static short ENUM=327;
+public final static short EVENTUAL=328;
+public final static short EVENTUALLY=329;
+public final static short EXPORT=330;
+public final static short EXTENDS=331;
+public final static short FACET=332;
+public final static short FORALL=333;
+public final static short FUNCTION=334;
+public final static short GIVEN=335;
+public final static short HIDDEN=336;
+public final static short HIDES=337;
+public final static short IMPLEMENTS=338;
+public final static short INTERFACE=339;
+public final static short IS=340;
+public final static short KNOW=341;
+public final static short KNOWS=342;
+public final static short LAMBDA=343;
+public final static short LET=344;
+public final static short METHOD=345;
+public final static short METHODS=346;
+public final static short MODULE=347;
+public final static short NAMESPACE=348;
+public final static short NATIVE=349;
+public final static short OBEYS=350;
+public final static short OCTET=351;
+public final static short ONEWAY=352;
+public final static short PACKAGE=353;
+public final static short PRIVATE=354;
+public final static short PROTECTED=355;
+public final static short PUBLIC=356;
+public final static short RAISES=357;
+public final static short RELIANCE=358;
+public final static short RELIANT=359;
+public final static short RELIES=360;
+public final static short RELY=361;
+public final static short REVEAL=362;
+public final static short SAKE=363;
+public final static short SIGNED=364;
+public final static short STATIC=365;
+public final static short STRUCT=366;
+public final static short SUCHTHAT=367;
+public final static short SUPPORTS=368;
+public final static short SUSPECT=369;
+public final static short SUSPECTS=370;
+public final static short SYNCHRONIZED=371;
+public final static short THIS=372;
+public final static short THROWS=373;
+public final static short TRANSIENT=374;
+public final static short TRUNCATABLE=375;
+public final static short UNSIGNED=376;
+public final static short UNUM=377;
+public final static short USES=378;
+public final static short USING=379;
+public final static short UTF8=380;
+public final static short UTF16=381;
+public final static short VALUETYPE=382;
+public final static short VIRTUAL=383;
+public final static short VOLATILE=384;
+public final static short WSTRING=385;
+public final static short EOL=386;
+public final static short OpLAnd=387;
+public final static short OpLOr=388;
+public final static short OpSame=389;
+public final static short OpNSame=390;
+public final static short OpButNot=391;
+public final static short OpLeq=392;
+public final static short OpABA=393;
+public final static short OpGeq=394;
+public final static short OpThru=395;
+public final static short OpTill=396;
+public final static short OpAsl=397;
+public final static short OpAsr=398;
+public final static short OpFlrDiv=399;
+public final static short OpMod=400;
+public final static short OpPow=401;
+public final static short OpAss=402;
+public final static short OpAssAdd=403;
+public final static short OpAssAnd=404;
+public final static short OpAssAprxDiv=405;
+public final static short OpAssFlrDiv=406;
+public final static short OpAssAsl=407;
+public final static short OpAssAsr=408;
+public final static short OpAssRemdr=409;
+public final static short OpAssMod=410;
+public final static short OpAssMul=411;
+public final static short OpAssOr=412;
+public final static short OpAssPow=413;
+public final static short OpAssSub=414;
+public final static short OpAssXor=415;
+public final static short Send=416;
+public final static short OpWhen=417;
+public final static short MapsTo=418;
+public final static short MatchBind=419;
+public final static short MisMatch=420;
+public final static short Audit=421;
+public final static short YYERRCODE=256;
+final static short yylhs[] = {                           -1,
+    0,    0,    0,    4,    4,    2,    6,    5,    5,    7,
+    7,    8,   10,   10,   11,   11,   11,   14,   14,   12,
+   12,   12,   12,   12,   12,   12,   12,   16,   16,   21,
+   21,   22,   22,   22,   22,   22,   22,   22,   22,   22,
+   24,   24,   23,   23,   23,   23,   23,   23,   25,   25,
+   25,   26,   26,   26,   28,   28,   27,   27,   27,   30,
+   30,   29,   29,   29,   29,   29,   29,   32,   32,   31,
+   31,   34,   34,   33,   33,   33,   33,   33,   35,   35,
+   35,   35,   35,   35,   35,   35,   35,   38,   38,   38,
+   38,   38,   38,   37,   37,   37,   36,   36,   36,   36,
+   36,   36,   36,   36,   36,   36,   36,   36,   36,   36,
+   36,   36,   36,   36,   36,   36,   36,   36,   36,   36,
+   36,   36,   36,   36,   36,   59,   59,   59,   59,   59,
+   59,   43,   46,   56,   56,   56,   54,   55,   57,   57,
+   69,   68,   68,   67,   67,   67,   44,   44,   44,   45,
+   45,   70,   70,   71,   71,   72,   72,   74,   74,   75,
+   76,   76,   64,   64,   77,   77,    3,    3,    3,   79,
+   79,   79,   79,   79,   80,   80,   81,   81,   82,   82,
+   83,   83,   84,   84,   85,   85,   78,   78,   78,   78,
+   78,   78,   78,   78,   78,   19,   19,   20,   20,   86,
+   86,   86,   86,   86,   86,   86,   88,   88,   88,   89,
+   89,   60,   60,   90,   90,   15,   15,   87,   87,   92,
+   92,   92,   92,   92,   93,   93,   93,   62,   62,   62,
+   63,   95,   96,   94,   94,   97,   65,   65,   98,   98,
+   99,    1,    1,    9,    9,  100,   73,   18,   18,   39,
+   39,   91,   91,   47,   47,  101,  101,   40,   13,   41,
+   41,   17,   17,   17,   17,   17,   17,   17,   17,   17,
+   17,   17,   17,   49,   49,   50,   61,   61,   61,  104,
+  104,  105,  105,  103,  103,   52,   52,   66,  106,   53,
+   53,   58,   58,  107,  107,  107,  107,  109,  109,  109,
+  109,  108,  108,  108,  111,  111,  112,  112,  113,  113,
+  110,  110,   42,   42,   48,   51,  102,  102,  102,  102,
+  102,  102,  102,  102,  102,  102,  102,  102,  102,  102,
+  102,  102,  102,  102,  102,  102,  102,  102,  102,  102,
+  102,  102,  102,  102,  102,  102,  102,  102,  102,  102,
+  102,  102,  102,  102,  102,  102,  102,  102,  102,  102,
+  102,  102,  102,  102,  102,  102,  102,  102,  102,  102,
+  102,  102,  102,  102,  102,  102,  102,  102,  102,  102,
+  102,  102,  102,  102,  102,  102,  102,  102,  102,  102,
+  102,  102,  102,  102,  102,  102,  102,  102,  102,  102,
+};
+final static short yylen[] = {                            2,
+    1,    1,    2,    1,    1,    3,    3,    1,    3,    1,
+    3,    1,    1,    2,    1,    3,    2,    1,    1,    1,
+    3,    3,    3,    3,    4,    3,    3,    1,    3,    1,
+    3,    1,    3,    3,    3,    3,    3,    3,    3,    3,
+    1,    1,    1,    3,    3,    3,    3,    3,    1,    3,
+    3,    1,    3,    3,    1,    1,    1,    3,    3,    1,
+    1,    1,    3,    3,    3,    3,    3,    1,    1,    1,
+    3,    1,    1,    1,    2,    2,    2,    2,    1,    1,
+    4,    4,    3,    3,    2,    3,    4,    2,    3,    3,
+    4,    2,    3,    1,    2,    3,    1,    1,    1,    1,
+    1,    1,    1,    3,    2,    1,    3,    3,    2,    4,
+    4,    5,    5,    1,    1,    1,    1,    3,    2,    2,
+    3,    2,    3,    2,    1,    2,    4,    3,    3,    4,
+    3,    1,    3,    4,    6,    7,    8,    5,    5,    6,
+    0,    6,    6,    0,    1,    1,    0,    1,    3,    1,
+    2,    2,    3,    1,    3,    1,    2,    1,    4,    2,
+    1,    4,    1,    1,    3,    2,    1,    3,    4,    1,
+    3,    5,    3,    5,    1,    2,    1,    2,    1,    2,
+    2,    3,    1,    1,    1,    3,    3,    1,    2,    1,
+    3,    1,    1,    3,    3,    4,    2,    4,    2,    1,
+    1,    2,    2,    3,    3,    1,    2,    2,    2,    1,
+    3,    1,    3,    1,    4,    2,    5,    1,    1,    4,
+    6,    4,    6,    4,    4,    5,    2,    4,    5,    2,
+    6,    4,    3,    0,    2,    3,    8,    6,    1,    3,
+    3,    0,    1,    1,    2,    0,    1,    3,    2,    1,
+    1,    1,    3,    1,    3,    3,    2,    1,    1,    1,
+    1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+    1,    1,    1,    4,    6,    4,    5,    1,    1,    1,
+    3,    1,    3,    1,    3,    1,    1,    2,    4,    0,
+    3,    5,    3,    1,    2,    2,    4,    2,    4,    2,
+    4,    2,    5,    4,    2,    3,    1,    4,    2,    2,
+    0,    2,    1,    1,    0,    0,    1,    1,    1,    1,
+    1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+    1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+    1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+    1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+    1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+    1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+    1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+    1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+};
+final static short yydefred[] = {                         0,
+  244,    0,    0,    0,    2,    0,  260,    0,    0,    0,
+  313,  314,    0,    0,  317,  318,  319,  320,  321,  322,
+  323,  324,  325,  326,  327,  328,  329,  330,  331,  332,
+  333,  334,  335,  336,  337,  338,  339,  340,  341,  342,
+  343,  344,  345,  346,  347,  348,  349,  350,  351,  352,
+  353,  354,  355,  356,  357,  358,  359,  360,  361,  362,
+  363,  364,  365,  366,  367,  368,  369,  370,  371,  372,
+  373,  374,  375,  376,  377,  378,  379,  380,  381,  382,
+  383,  384,  385,  386,  387,  388,  389,  390,  391,  392,
+  393,  394,  395,  396,  397,  398,  399,  400,    0,    0,
+    0,    0,    3,    0,  192,  193,    0,    0,    0,  177,
+    0,  170,  175,  261,   97,   98,   99,  100,  101,    0,
+    0,  103,    0,  315,  315,    0,    0,    4,    0,    0,
+    5,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,    0,    8,   12,    0,   15,  132,    0,    0,
+    0,    0,   30,    0,    0,    0,    0,    0,   62,    0,
+    0,   94,    0,   80,    0,  102,    0,  106,    0,  114,
+  115,  116,  117,  125,    0,    0,  245,    0,    0,    0,
+  259,    0,    0,    0,    0,    0,  176,  189,    0,  247,
+    0,    0,  156,    0,    0,    0,  161,    0,    0,    0,
+    0,    0,    0,  179,  178,    0,    0,    0,    0,    0,
+    0,    0,    0,  218,  219,    0,    0,    0,    0,  201,
+  200,    0,    0,  206,  315,    0,    0,    0,  315,    0,
+    0,  124,    0,   78,   77,   75,   76,    0,    0,    0,
+    0,    0,  250,    0,  254,  119,  120,  122,    0,    0,
+    0,    0,    0,    0,    0,    0,  207,    6,    0,    0,
+    0,    0,    0,  262,  263,  264,  265,  266,    0,  267,
+  268,  269,  270,  271,  272,  273,    0,    0,    0,    0,
+    0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,    0,    0,    0,    0,    0,    0,    0,  258,
+    0,    0,    0,    0,    0,    0,  150,  105,    0,    0,
+    0,    0,    0,    0,    0,    0,    0,    0,  109,    0,
+    0,  126,  278,  279,    0,  194,  195,    0,    0,  191,
+  208,  209,  166,    0,    0,    0,  157,    0,    0,  160,
+    0,   10,  149,  187,    0,    0,  154,  185,    0,    0,
+  183,  181,  184,    0,  180,  168,  118,  121,  104,  146,
+  145,    0,    0,    0,    0,  202,  203,  129,    0,    0,
+  252,    0,  246,    0,    0,    0,  123,    0,    0,    0,
+    0,  257,    0,  107,  108,    0,    0,    0,    0,    0,
+    0,    0,    0,    9,    0,   16,    0,    0,   21,   23,
+    0,   18,   22,   19,   26,   27,   31,   33,   34,   42,
+   41,   38,   39,   40,   35,   36,   37,   45,   46,   47,
+   44,   48,    0,    0,   56,    0,   53,    0,   61,    0,
+   58,   59,   69,   68,   65,   67,   63,   64,   66,   73,
+   72,   71,    0,    0,    0,    0,    0,    0,    0,  249,
+    0,    0,    0,  152,    0,  151,    0,    0,    0,  164,
+    0,    0,  128,  246,    0,    0,    0,  131,    0,    0,
+  246,    0,    0,    0,  214,    0,  196,  198,  165,    0,
+    0,    0,    0,    7,    0,  133,  169,    0,    0,  182,
+    0,    0,  316,  204,  205,    0,    0,  236,  315,    0,
+  286,    0,  315,  246,    0,    0,    0,    0,    0,  302,
+  293,  256,    0,  255,  253,    0,    0,   25,    0,  216,
+    0,    0,   81,    0,  248,    0,  153,  110,    0,    0,
+  316,    0,  287,  111,  158,    0,    0,    0,  230,  130,
+  316,    0,  280,    0,  233,    0,  127,    0,  172,  159,
+  174,    0,  162,   11,  155,  186,  315,  139,    0,    0,
+    0,    0,  288,    0,  138,    0,    0,  239,    0,  284,
+    0,    0,    0,  305,    0,  307,    0,    0,    0,    0,
+  294,    0,    0,    0,  312,    0,  315,  315,  112,    0,
+  113,    0,    0,  235,  274,    0,    0,    0,    0,    0,
+  232,    0,    0,  315,  140,    0,    0,    0,    0,    0,
+    0,    0,  276,    0,    0,  310,  309,    0,  306,  304,
+  295,  298,  300,  292,  296,    0,    0,    0,    0,    0,
+  135,  228,    0,  316,    0,    0,    0,  281,    0,  277,
+  215,    0,    0,  231,    0,  291,  241,  238,  240,    0,
+  285,    0,    0,    0,    0,  303,  217,  316,  136,  229,
+  275,    0,    0,    0,    0,    0,    0,  283,  316,    0,
+  289,    0,  308,  297,  299,  301,  137,    0,  224,    0,
+    0,    0,  227,  220,  222,    0,    0,  237,  316,    0,
+  316,    0,  143,  142,  223,  225,  221,    0,  226,
+};
+final static short yydgoto[] = {                          3,
+  198,    5,  545,  186,  143,  381,  351,  144,    6,  352,
+  146,  147,  148,  413,  443,  149,  277,  312,  105,  106,
+  152,  153,  154,  422,  155,  156,  157,  437,  158,  441,
+  159,  445,  160,  452,  161,  162,  163,  164,  241,  390,
+  107,  165,  166,  167,  318,  168,  242,  169,  329,  387,
+  570,  509,  575,  170,  171,  172,  173,  232,  174,  175,
+  332,  479,  222,  469,  228,  510,  372,  568,  569,  319,
+  361,  192,  193,  194,  195,  196,  197,  110,  111,  112,
+  113,  205,  206,  362,  363,  223,  224,  176,  225,  486,
+  244,  608,  675,  693,  333,  334,  230,  577,  578,  511,
+  245,  114,  581,  554,  610,  573,  592,  391,  593,  520,
+  516,  585,  586,
+};
+final static short yysindex[] = {                      -310,
+    0,15951,    0,14168,    0, -280,    0, -127, -122,19458,
+    0,    0,19458,   87,    0,    0,    0,    0,    0,    0,
+    0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,    0,    0,    0,    0,    0,    0,16556,19458,
+12002, -229,    0,  104,    0,    0,    0,  163,  -95,    0,
+  142,    0,    0,    0,    0,    0,    0,    0,    0,  -44,
+    6,    0,14521,    0,    0,19458,19086,    0,19458,16806,
+    0,  163,19086,19458,16556,16556,16556, -306,   -9,    8,
+ -229,15129, -229,    0,    0,  190,    0,    0,  735, -125,
+ -109, -107,    0,  -24,   76,   66,   52,    2,    0,  -84,
+12592,    0,  265,    0,12252,    0,  -23,    0,  694,    0,
+    0,    0,    0,    0,  197,  -93,    0,  201,  216,  285,
+    0,  290,14521,19458,19458,19086,    0,    0,16680,    0,
+  -48,  260,    0,  -27,  284,  -26,    0,14168,  332,14521,
+ -229,  -40,  456,    0,    0,   46,14521,  255,  257,   49,
+16075,16075,  285,    0,    0,  127,  131,19458,19458,    0,
+    0,  271,  -14,    0,    0,  290, -229,  271,    0,  -20,
+  289,    0,17870,    0,    0,    0,    0,19458,14168,   -5,
+  323,   17,    0,  373,    0,    0,    0,    0,  379,  164,
+  176,19458,19458,   87,   32,  104,    0,    0,12721,14168,
+  265,14521,14168,    0,    0,    0,    0,    0,14168,    0,
+    0,    0,    0,    0,    0,    0,14650,14168,14168,14521,
+14521,14521,15003,15951,15951,15003,15003,15003,14521,14521,
+14521,14521,14521,14521,14521,15003,14521,15003,15003,15003,
+15003,15003,15003,15003,15003,18588, -229,19458,  265,    0,
+ -229,  147,18588,  147,  265, -152,    0,    0,   58,15951,
+12127,  163,  163,  271,  271,  163,17994, -229,    0, -229,
+17400,    0,    0,    0,19458,    0,    0,14521,14521,    0,
+    0,    0,    0,15951,  396, -229,    0,  325, -229,    0,
+ -229,    0,    0,    0,  409,15951,    0,    0, -229,15951,
+    0,    0,    0,  456,    0,    0,    0,    0,    0,    0,
+    0,  271,  197,  327,  333,    0,    0,    0,19458,  419,
+    0,   40,    0,  431,19086, -229,    0, -229, -229,   61,
+   86,    0, -229,    0,    0, -306, -229,    0,  348,  350,
+  285,  290,14168,    0,15129,    0,  147, -107,    0,    0,
+  -12,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,  -96,  -96,    0,   52,    0,   52,    0,    2,
+    0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,  147,  265,  383,  265,  147,  437, -126,    0,
+  147,  265,  147,    0, -152,    0,  271,  -48,  193,    0,
+  271,  289,    0,    0,  271,15601,   89,    0,  271,14039,
+    0,  271,15951,  271,    0,  436,    0,    0,    0,16423,
+15951,16423,12127,    0,12721,    0,    0,  357,  358,    0,
+  210, -112,    0,    0,    0,  436,15601,    0,    0,    0,
+    0, -229,    0,    0,19210,  445, -184, -229,19458,    0,
+    0,    0,   -5,    0,    0,    0,    0,    0,  104,    0,
+  102,  147,    0,  147,    0,  147,    0,    0,14168,  206,
+    0,    0,    0,    0,    0,  451,15601,14521,    0,    0,
+    0, -229,    0,    0,    0,  271,    0, -229,    0,    0,
+    0,  -48,    0,    0,    0,    0,    0,    0,  220,  210,
+  455,  221,    0,  214,    0,   90,  179,    0,  463,    0,
+  381,  446,  446,    0,  -10,    0,  446, -229,18712,18712,
+    0,  390, -229,  477,    0, -229,    0,    0,    0, -103,
+    0,  462,  480,    0,    0,  397, -133, -229,    0,  400,
+    0,19458,16075,    0,    0,  462,15951,  271,15951,  462,
+ -229,15951,    0,  242, -229,    0,    0, -229,    0,    0,
+    0,    0,    0,    0,    0, -213,  446,  213,  271,  -64,
+    0,    0,  462,    0,  163,18836,18836,    0, -229,    0,
+    0,  197,16075,    0,  271,    0,    0,    0,    0,  230,
+    0,19210, -229,18712,18712,    0,    0,    0,    0,    0,
+    0, -111,15601,  -30,  271,  114,  271,    0,    0,  271,
+    0,  462,    0,    0,    0,    0,    0,  163,    0,  489,
+14168,15601,    0,    0,    0,  210,  210,    0,    0,  462,
+    0,  497,    0,    0,    0,    0,    0,  462,    0,
+};
+final static short yyrindex[] = {                      9616,
+    0,   81,    0,  645,    0, 8526,    0,    0,    0,    0,
+    0,    0,    0, 8650,    0,    0,    0,    0,    0,    0,
+    0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,    0,    0,    0,    0,    0,    0,  821,    0,
+   20,13686,    0, 8916,    0,    0,  969,    0,    0,    0,
+ 9219,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,  821,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,    0,    0,  821,  821,  821,13075,    0,    0,
+13686,   81,  540,    0,    0,   25,    0,    0,  779,    0,
+    0, 9416,    0, 9379, 8346, 7962, 7503, 7330,    0, 7291,
+ 6907,    0, 5168,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,    0,    0,17524,17152,    0,    0,    0, 8951,
+    0, 8984,  821,    0,    0,    0,    0,    0,    0,    0,
+  -35,    0,    0,   30,    0,  449,    0,  821,    0,  821,
+13686,    0,    0,    0,    0,    0,  821,    0,    0,    0,
+  -88,  -86,11183,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,18340,    0,    0,11529,13686,    0,    0,    0,
+    0,    0,    0,    0,    0,    0,    0,    0,  661,   29,
+    0,    0,    0,   33,    0,    0,    0,    0,    0,    0,
+    0,    0,    0, 9773,    0, 1135,    0,    0,  791,  391,
+    0,  821,  821,    0,    0,    0,    0,    0,  821,    0,
+    0,    0,    0,    0,    0,    0,  821,  821,  821,  821,
+  821,  821,  821,   81,   81,  821,  821,  821,  821,  821,
+  821,  821,  821,  821,  821,  821,  821,  821,  821,  821,
+  821,  821,  821,  821,  821,    0,13075,    0, 5589,    0,
+13204, 1522,    0, 2848, 5748,    0,    0,    0,    0,   81,
+   81,    0,    0,    0,    0,    0,    0,13557,    0,  -80,
+    0,    0,    0,    0,    0,    0,    0,  821,  821,    0,
+    0,    0,    0,   81, 9142,15477,    0, 9182,11654,    0,
+   -8,    0,    0,    0,    0,   81,    0,    0,13686,   81,
+    0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,  -94,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,    0,    0,    0,  -60,    0,18960,  -37, -105,
+    0,    0,13686,    0,    0,13686,13686, 1681,    0,    0,
+10119,10243,  821,    0,   81,    0,  746, 9449,    0,    0,
+13686,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0, 8193, 8269,    0, 7809,    0, 7886,    0, 7367,
+    0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+    0,    0, 3269, 6169,    0, 6328, 2102,    0,    0,    0,
+ 3428, 6749, 3849,    0,    0,    0,    0,  261,    0,    0,
+    0,    0,    0,    0,    0,    5,  423,    0,    0,  821,
+    0,    0,   81,    0,    0,17276,    0,    0,    0,   81,
+   81,   81,   81,    0,  -18,    0,    0,    0,    0,    0,
+  276,    0,    0,    0,    0,18464,    5,    0,    0, 2261,
+    0,13686,    0,    0,  511,    0,  426,18960,    0,    0,
+    0,    0,    0,    0,    0,10589,10713,    0,11059,    0,
+    0, 4008,    0, 4429,    0, 4588,    0,    0,  821, 5009,
+    0, 2682,    0,    0,    0,    0,    5,  821,    0,    0,
+    0,  429,    0,  280,    0,    0,    0,19582,    0,    0,
+    0,    0,    0,    0,    0,    0,    0,    0,    0,  276,
+    0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
+  270,    7,    7,    0,  517,    0, -105,  429,    0,    0,
+    0,    0,  429,    0,    0,13686,    0,    0,    0,    0,
+    0,  423,    0,    0,    0,    0,    0,  -80,  -69,    0,
+    0,    0,  -86,    0,    0,  423,   81,    0,   81,  423,
+13686,   81,    0,    0,  -65,    0,    0,19334,    0,    0,
+    0,    0,    0,    0,    0,  440, -105,    0,    0,    0,
+    0,    0,  423,    0,    0,    0,    0,    0,  429,    0,
+    0,  -94,  -88,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,  429,    0,    0,    0,    0,    0,    0,    0,
+    0,    0,    5,  423,    0,  423,    0,    0,    0,    0,
+    0,  423,    0,    0,    0,    0,    0,    0,    0,    0,
+  821,    5,    0,    0,    0,  276,  276,    0,    0,  423,
+    0,    0,    0,    0,    0,    0,    0,  423,    0,
+};
+final static short yygindex[] = {                         0,
+    1,    0,  243,   37,    0,  -98,   91,  302, -137,   -1,
+    0, -247,   -2,    0,  903,    0,    0,  295,  159,  188,
+  307,  293,  -49,  143,   45,   67,  -71,    0,   57,  275,
+  233,  457,  272,    0,    0,  -46,    0,    0,  -67, -146,
+  580,   48, -231,   19,    0,  -70,    0,  510,  322,   98,
+   51,  106,   36,    0,    0,  -17,    0,    0,  310,    0,
+ -331,  251,    0,    0,    0,  110, -207, -498,    0,    0,
+ -269, -343,  -83,  -34,    0,    0, -257,  407, -301,    0,
+    0,    0,    0,  234,    0, -118,    0,    0,  -76,  218,
+ -225,    0,  -62, -414, -488,   -4,    0,    0,  -21, -190,
+  211,    0,   59,    0,    0,    0,    0, -512,    0, -500,
+   88,    0,  -50,
+};
+final static int YYTABLESIZE=19967;
 
-    //These two tables are not statically initialized, but rather
+//These two tables are not statically initialized, but rather
 //initialized on first use, so that a failure to initialize them
 //can successfully report the problem.
-    static private short[] yytable = null;
-
-    static private short[] yycheck = null;
-
-    /** Ensures that yytable and yycheck are initialized. */
-    static private void initTables() {
-        if (null != yycheck) {
-            return;
+static private short[] yytable = null;
+static private short[] yycheck = null;
+/** Ensures that yytable and yycheck are initialized. */
+static private void initTables() {
+    if (null != yycheck) {
+        return;
+    }
+    try {
+        String rName = "org/erights/e/elang/syntax/ParserTables.data";
+        InputStream inp = ClassLoader.getSystemResourceAsStream(rName);
+        if (null == inp) {
+            throw new RuntimeException(rName + " not found");
         }
-        try {
-            String rName = "org/erights/e/elang/syntax/ParserTables.data";
-            InputStream inp = ClassLoader.getSystemResourceAsStream(rName);
-            if (null == inp) {
-                throw new RuntimeException(rName + " not found");
-            }
-            ObjectInput obInp = new ObjectInputStream(inp);
-            yytable = (short[])obInp.readObject();
-            yycheck = (short[])obInp.readObject();
-            long hash = EYaccFixer.checkhash(yytable, yycheck);
-            if (hash != -4408874519322207609L) {
-                throw new RuntimeException(rName + " bad checkhash: " +
-                                           hash);
-            }
-        } catch (Exception ex) {
-            throw ThrowableSugar.backtrace(ex, "initializing parser");
+        ObjectInput obInp = new ObjectInputStream(inp);
+        yytable = (short[])obInp.readObject();
+        yycheck = (short[])obInp.readObject();
+        long hash = EYaccFixer.checkhash(yytable, yycheck);
+        if (hash != -4408874519322207609L) {
+            throw new RuntimeException(rName + " bad checkhash: " +
+                                       hash);
         }
+    } catch (Exception ex) {
+        throw ThrowableSugar.backtrace(ex, "initializing parser");
     }
+}
 
-    final static short YYFINAL = 3;
+final static short YYFINAL=3;
+final static short YYMAXTOKEN=421;
+final static String yyname[] = {
+"end-of-file",null,null,null,null,null,null,null,null,null,null,null,null,null,
+null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+null,null,null,"'!'",null,null,"'$'","'%'","'&'",null,"'('","')'","'*'","'+'",
+"','","'-'","'.'","'/'",null,null,null,null,null,null,null,null,null,null,"':'",
+"';'","'<'",null,"'>'","'?'","'@'",null,null,null,null,null,null,null,null,null,
+null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+null,"'['",null,"']'","'^'",null,null,null,null,null,null,null,null,null,null,
+null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+null,null,"'{'","'|'","'}'","'~'",null,null,null,null,null,null,null,null,null,
+null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+null,null,null,null,null,null,null,null,null,"LiteralInteger","LiteralFloat64",
+"LiteralChar","LiteralString","LiteralTwine","ID","VerbAssign","QuasiOpen",
+"QuasiClose","DollarIdent","AtIdent","DollarOpen","AtOpen","URI","URIStart",
+"BodyStartWord","BodyNextWord","VTableStartWord","VTableNextWord","BIND",
+"CATCH","CLASS","DEF","DELEGATE","ELSE","ESCAPE","FINALLY","FOR","IF","IN",
+"MATCH","META","PRAGMA","SWITCH","THUNK","TO","TRY","VAR","WHEN","WHILE","_",
+"DEFINE","ON","SELECT","TYPEDEF","ABSTRACT","AN","AS","ATTRIBUTE","BE","BEGIN",
+"BEHALF","BELIEF","BELIEVE","BELIEVES","CASE","CONST","CONSTRUCTOR","CONTEXT",
+"DECLARE","DEFAULT","DEFMACRO","DEPRECATED","DISPATCH","DO","ENCAPSULATE",
+"ENCAPSULATED","ENCAPSULATES","END","ENSURE","ENUM","EVENTUAL","EVENTUALLY",
+"EXPORT","EXTENDS","FACET","FORALL","FUNCTION","GIVEN","HIDDEN","HIDES",
+"IMPLEMENTS","INTERFACE","IS","KNOW","KNOWS","LAMBDA","LET","METHOD","METHODS",
+"MODULE","NAMESPACE","NATIVE","OBEYS","OCTET","ONEWAY","PACKAGE","PRIVATE",
+"PROTECTED","PUBLIC","RAISES","RELIANCE","RELIANT","RELIES","RELY","REVEAL",
+"SAKE","SIGNED","STATIC","STRUCT","SUCHTHAT","SUPPORTS","SUSPECT","SUSPECTS",
+"SYNCHRONIZED","THIS","THROWS","TRANSIENT","TRUNCATABLE","UNSIGNED","UNUM",
+"USES","USING","UTF8","UTF16","VALUETYPE","VIRTUAL","VOLATILE","WSTRING","EOL",
+"OpLAnd","OpLOr","OpSame","OpNSame","OpButNot","OpLeq","OpABA","OpGeq","OpThru",
+"OpTill","OpAsl","OpAsr","OpFlrDiv","OpMod","OpPow","OpAss","OpAssAdd",
+"OpAssAnd","OpAssAprxDiv","OpAssFlrDiv","OpAssAsl","OpAssAsr","OpAssRemdr",
+"OpAssMod","OpAssMul","OpAssOr","OpAssPow","OpAssSub","OpAssXor","Send",
+"OpWhen","MapsTo","MatchBind","MisMatch","Audit",
+};
+final static String yyrule[] = {
+"$accept : start",
+"start : br",
+"start : topExpr",
+"start : MatchBind pattern",
+"define : DEF",
+"define : DEFINE",
+"topExpr : br topSeqs br",
+"eExpr : br seqs br",
+"topSeqs : topSeq",
+"topSeqs : topSeqs EOLs topSeq",
+"seqs : seq",
+"seqs : seqs EOLs seq",
+"topSeq : seq",
+"seq : assigns",
+"seq : assigns ';'",
+"assigns : assign",
+"assigns : assigns ';' assign",
+"assigns : define noun",
+"nAssign : assign",
+"nAssign : plural",
+"assign : cond",
+"assign : cond OpAss assign",
+"assign : cond assignop nAssign",
+"assign : cond OpAssAsr assign",
+"assign : cond VerbAssign parenArgs",
+"assign : define pattern OpAss assign",
+"assign : binder OpAss assign",
+"assign : varNamer OpAss assign",
+"cond : condAnd",
+"cond : cond OpLOr condAnd",
+"condAnd : comp",
+"condAnd : condAnd OpLAnd comp",
+"comp : order",
+"comp : order OpSame order",
+"comp : order OpNSame order",
+"comp : order '&' nOrder",
+"comp : order '|' nOrder",
+"comp : order '^' nOrder",
+"comp : order OpButNot nOrder",
+"comp : order MatchBind pattern",
+"comp : order MisMatch pattern",
+"nOrder : order",
+"nOrder : plural",
+"order : interval",
+"order : interval '<' interval",
+"order : interval OpLeq interval",
+"order : interval OpABA interval",
+"order : interval OpGeq interval",
+"order : interval '>' interval",
+"interval : shift",
+"interval : shift OpThru shift",
+"interval : shift OpTill shift",
+"shift : add",
+"shift : shift OpAsl nAdd",
+"shift : shift OpAsr add",
+"nAdd : add",
+"nAdd : plural",
+"add : mult",
+"add : add '+' nMult",
+"add : add '-' nMult",
+"nMult : mult",
+"nMult : plural",
+"mult : pow",
+"mult : mult '*' nPow",
+"mult : mult '/' nPow",
+"mult : mult OpFlrDiv nPow",
+"mult : mult '%' nPow",
+"mult : mult OpMod nPow",
+"nPow : pow",
+"nPow : plural",
+"pow : prefix",
+"pow : prefix OpPow nPrefix",
+"nPrefix : prefix",
+"nPrefix : plural",
+"prefix : postfix",
+"prefix : '!' prim",
+"prefix : '~' prim",
+"prefix : '-' prim",
+"prefix : '&' noun",
+"postfix : call",
+"postfix : metaExpr",
+"postfix : postfix '[' argList ']'",
+"postfix : postfix Send verb parenArgs",
+"postfix : postfix Send parenArgs",
+"postfix : postfix Send verb",
+"postfix : postfix verb",
+"postfix : postfix '.' ident",
+"postfix : postfix '.' ident parenArgs",
+"metaExpr : metaoid parenArgs",
+"metaExpr : metaoid verb parenArgs",
+"metaExpr : metaoid Send parenArgs",
+"metaExpr : metaoid Send verb parenArgs",
+"metaExpr : metaoid verb",
+"metaExpr : metaoid Send verb",
+"call : prim",
+"call : call parenArgs",
+"call : postfix verb parenArgs",
+"prim : LiteralInteger",
+"prim : LiteralFloat64",
+"prim : LiteralChar",
+"prim : LiteralString",
+"prim : LiteralTwine",
+"prim : nounExpr",
+"prim : URI",
+"prim : URIStart add '>'",
+"prim : quasiParser quasiExpr",
+"prim : parenExpr",
+"prim : '[' argList ']'",
+"prim : '[' maps ']'",
+"prim : begin body",
+"prim : begin ESCAPE pattern body",
+"prim : begin WHILE parenExpr body",
+"prim : begin SWITCH parenExpr caseList end",
+"prim : begin TRY body catchList finallyClause",
+"prim : forExpr",
+"prim : whenExpr",
+"prim : ifExpr",
+"prim : macro",
+"prim : DollarOpen LiteralInteger '}'",
+"prim : '$' LiteralInteger",
+"prim : '$' '$'",
+"prim : AtOpen LiteralInteger '}'",
+"prim : '@' LiteralInteger",
+"prim : SELECT parenExpr caseList",
+"prim : TYPEDEF oType",
+"prim : object",
+"object : defAudits vTable",
+"object : defAudits begin funcHead body",
+"object : begin THUNK body",
+"object : CLASS classHead body",
+"object : begin _ funcHead body",
+"object : begin _ body",
+"nounExpr : noun",
+"parenExpr : '(' eExpr ')'",
+"ifExpr : begin IF parenExpr body",
+"ifExpr : begin IF parenExpr body ELSE ifExpr",
+"ifExpr : begin IF parenExpr body ELSE begin body",
+"forExpr : begin FOR iterPattern IN assign begin body end",
+"whenExpr : WHEN whenHead body catches finallyClause",
+"macro : BodyStartWord begin macroArg body restMacro",
+"macro : VTableStartWord begin macroArg vTable end restMacro",
+"$$1 :",
+"restMacro : $$1 BodyNextWord begin macroArg body restMacro",
+"restMacro : VTableNextWord begin macroArg vTable end restMacro",
+"macroArg :",
+"macroArg : parenExpr",
+"macroArg : pattern",
+"quasiParser :",
+"quasiParser : ident",
+"quasiParser : '(' eExpr ')'",
+"quasiExpr : QuasiClose",
+"quasiExpr : innerExprs QuasiClose",
+"innerExprs : QuasiOpen innerExpr",
+"innerExprs : innerExprs QuasiOpen innerExpr",
+"innerExpr : DollarIdent",
+"innerExpr : DollarOpen eExpr '}'",
+"patternList : emptyBr",
+"patternList : patterns br",
+"patterns : pattern",
+"patterns : patterns ',' br pattern",
+"mapPatternList : mapPatterns br",
+"mapPatterns : mapPattern",
+"mapPatterns : mapPatterns ',' br mapPattern",
+"iterPattern : pattern",
+"iterPattern : mapPattern",
+"mapPattern : pattern MapsTo pattern",
+"mapPattern : MapsTo namer",
+"pattern : listPatt",
+"pattern : listPatt '?' order",
+"pattern : metaoid parenExpr MapsTo pattern",
+"listPatt : eqPatt",
+"listPatt : '[' patternList ']'",
+"listPatt : '[' patternList ']' '+' listPatt",
+"listPatt : '[' mapPatternList ']'",
+"listPatt : '[' mapPatternList ']' '|' listPatt",
+"eqPatt : quasiPatt",
+"eqPatt : OpSame prim",
+"quasiPatt : namer",
+"quasiPatt : quasiParser quasiPattern",
+"quasiPattern : QuasiClose",
+"quasiPattern : innerThings QuasiClose",
+"innerThings : QuasiOpen innerThing",
+"innerThings : innerThings QuasiOpen innerThing",
+"innerThing : innerExpr",
+"innerThing : innerPattern",
+"innerPattern : AtIdent",
+"innerPattern : AtOpen pattern '}'",
+"namer : noun ':' order",
+"namer : noun",
+"namer : '&' noun",
+"namer : _",
+"namer : _ ':' order",
+"namer : binder",
+"namer : varNamer",
+"namer : DollarOpen LiteralInteger '}'",
+"namer : AtOpen LiteralInteger '}'",
+"binder : BIND noun ':' order",
+"binder : BIND noun",
+"varNamer : VAR noun ':' order",
+"varNamer : VAR noun",
+"oName : noun",
+"oName : _",
+"oName : BIND noun",
+"oName : VAR noun",
+"oName : DollarOpen LiteralInteger '}'",
+"oName : AtOpen LiteralInteger '}'",
+"oName : litString",
+"defName : define oName",
+"defName : BIND noun",
+"defName : VAR noun",
+"audits : oName",
+"audits : oName Audit nounExprs",
+"defAudits : defName",
+"defAudits : defName Audit nounExprs",
+"nounExprs : nounExpr",
+"nounExprs : nounExprs ',' br nounExpr",
+"plural : '(' ')'",
+"plural : '(' eExpr ',' args ')'",
+"litString : LiteralString",
+"litString : LiteralTwine",
+"method : begin TO methHead body",
+"method : begin TO verb OpAss assign end",
+"method : begin ON methHead body",
+"method : begin META parenExpr MapsTo parenExpr end",
+"method : begin META parenExpr body",
+"methHead : '(' patternList ')' resultGuard",
+"methHead : verb '(' patternList ')' resultGuard",
+"methHead : verb resultGuard",
+"funcHead : '(' patternList ')' resultGuard",
+"funcHead : verb '(' patternList ')' resultGuard",
+"funcHead : verb resultGuard",
+"classHead : audits begin '(' patternList ')' resultGuard",
+"matcher : begin MATCH pattern body",
+"delegator : begin DELEGATE body",
+"resultGuard :",
+"resultGuard : ':' order",
+"whenArgs : '(' args ')'",
+"whenHead : whenArgs OpWhen audits begin '(' patterns ')' resultGuard",
+"whenHead : audits begin '(' whenClauses ')' resultGuard",
+"whenClauses : whenClause",
+"whenClauses : whenClauses ',' whenClause",
+"whenClause : eExpr OpWhen pattern",
+"br :",
+"br : EOLs",
+"EOLs : EOL",
+"EOLs : EOLs EOL",
+"emptyList :",
+"emptyBr : br",
+"parenArgs : '(' argList ')'",
+"parenArgs : parenArgs object",
+"argList : emptyBr",
+"argList : args",
+"args : eExpr",
+"args : args ',' eExpr",
+"maps : map",
+"maps : maps ',' map",
+"map : eExpr MapsTo eExpr",
+"map : MapsTo nounExpr",
+"verb : ident",
+"noun : ident",
+"ident : ID",
+"ident : reserved",
+"assignop : OpAssAdd",
+"assignop : OpAssAnd",
+"assignop : OpAssAprxDiv",
+"assignop : OpAssFlrDiv",
+"assignop : OpAssAsl",
+"assignop : OpAssRemdr",
+"assignop : OpAssMod",
+"assignop : OpAssMul",
+"assignop : OpAssOr",
+"assignop : OpAssPow",
+"assignop : OpAssSub",
+"assignop : OpAssXor",
+"body : '{' br '}' end",
+"body : '{' br seqs br '}' end",
+"caseList : '{' br matchList '}'",
+"vTable : '{' br methodList vMatchList '}'",
+"vTable : matcher",
+"vTable : delegator",
+"methodList : emptyList",
+"methodList : methodList method br",
+"vMatchList : matchList",
+"vMatchList : matchList delegator br",
+"matchList : emptyList",
+"matchList : matchList matcher br",
+"catchList : emptyList",
+"catchList : catches",
+"catches : catchList catchClause",
+"catchClause : begin CATCH pattern body",
+"finallyClause :",
+"finallyClause : begin FINALLY body",
+"oType : audits '{' br messageList '}'",
+"oType : audits mType EOL",
+"messageList : emptyList",
+"messageList : DELEGATE br",
+"messageList : messages br",
+"messageList : messages EOLs DELEGATE br",
+"messages : TO mType",
+"messages : messages EOLs TO mType",
+"messages : ON mType",
+"messages : messages EOLs ON mType",
+"mType : verb optType",
+"mType : verb '(' pTypeList ')' optType",
+"mType : '(' pTypeList ')' optType",
+"pTypeList : br emptyList",
+"pTypeList : br pTypes br",
+"pTypes : pType",
+"pTypes : pTypes ',' br pType",
+"pType : noun optType",
+"pType : _ optType",
+"optType :",
+"optType : ':' nounExpr",
+"metaoid : META",
+"metaoid : PRAGMA",
+"begin :",
+"end :",
+"reserved : ABSTRACT",
+"reserved : AN",
+"reserved : AS",
+"reserved : ATTRIBUTE",
+"reserved : BE",
+"reserved : BEGIN",
+"reserved : BEHALF",
+"reserved : BELIEF",
+"reserved : BELIEVE",
+"reserved : BELIEVES",
+"reserved : CASE",
+"reserved : CONST",
+"reserved : CONSTRUCTOR",
+"reserved : CONTEXT",
+"reserved : DECLARE",
+"reserved : DEFAULT",
+"reserved : DEFMACRO",
+"reserved : DEPRECATED",
+"reserved : DISPATCH",
+"reserved : DO",
+"reserved : ENCAPSULATE",
+"reserved : ENCAPSULATED",
+"reserved : ENCAPSULATES",
+"reserved : END",
+"reserved : ENSURE",
+"reserved : ENUM",
+"reserved : EVENTUAL",
+"reserved : EVENTUALLY",
+"reserved : EXPORT",
+"reserved : EXTENDS",
+"reserved : FACET",
+"reserved : FORALL",
+"reserved : FUNCTION",
+"reserved : GIVEN",
+"reserved : HIDDEN",
+"reserved : HIDES",
+"reserved : IMPLEMENTS",
+"reserved : INTERFACE",
+"reserved : IS",
+"reserved : KNOW",
+"reserved : KNOWS",
+"reserved : LAMBDA",
+"reserved : LET",
+"reserved : METHOD",
+"reserved : METHODS",
+"reserved : MODULE",
+"reserved : NAMESPACE",
+"reserved : NATIVE",
+"reserved : OBEYS",
+"reserved : OCTET",
+"reserved : ONEWAY",
+"reserved : PACKAGE",
+"reserved : PRIVATE",
+"reserved : PROTECTED",
+"reserved : PUBLIC",
+"reserved : RAISES",
+"reserved : RELIANCE",
+"reserved : RELIANT",
+"reserved : RELIES",
+"reserved : RELY",
+"reserved : REVEAL",
+"reserved : SAKE",
+"reserved : SIGNED",
+"reserved : STATIC",
+"reserved : STRUCT",
+"reserved : SUCHTHAT",
+"reserved : SUPPORTS",
+"reserved : SUSPECT",
+"reserved : SUSPECTS",
+"reserved : SYNCHRONIZED",
+"reserved : THIS",
+"reserved : THROWS",
+"reserved : TRANSIENT",
+"reserved : TRUNCATABLE",
+"reserved : UNSIGNED",
+"reserved : UNUM",
+"reserved : USES",
+"reserved : USING",
+"reserved : UTF8",
+"reserved : UTF16",
+"reserved : VALUETYPE",
+"reserved : VIRTUAL",
+"reserved : VOLATILE",
+"reserved : WSTRING",
+};
+
+//#line 1188 "e.y"
+
+
+/**
+ *
+ */
+static public final StaticMaker EParserMaker =
+    StaticMaker.make(EParser.class);
+
+/** 
+ * caches previous simple parses (as is used for quasi-parsing)
+ */
+static private IdentityCacheTable OurCache =
+    new IdentityCacheTable(ENode.class, 100);
+
+/**
+ *
+ */
+static private final ConstMap DefaultProps = 
+  ConstMap.fromProperties(System.getProperties());
+
+
+
+/** contains all the tokens after yylval */
+private ELexer myLexer;
+
+/** 
+ * Do we escape after parsing only one expression, or do we parse the
+ * entire input?
+ */
+private boolean myOnlyOneExprFlag;
+
+/** how we exit yacc logic */
+private Ejector myEscape;
+
+
+/**
+ *
+ */
+public EParser(ELexer lexer) {
+    this(DefaultProps, lexer, false, false);
+}
 
-    final static short YYMAXTOKEN = 421;
+/**
+ *
+ */
+public EParser(ConstMap props, ELexer lexer) {
+    this(props, lexer, false, false);
+}
 
-    final static String yyname[] = {
-        "end-of-file",null,null,null,null,null,null,null,null,null,null,null,null,null,
-        null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
-        null,null,null,"'!'",null,null,"'$'","'%'","'&'",null,"'('","')'","'*'","'+'",
-        "','","'-'","'.'","'/'",null,null,null,null,null,null,null,null,null,null,"':'",
-        "';'","'<'",null,"'>'","'?'","'@'",null,null,null,null,null,null,null,null,null,
-        null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
-        null,"'['",null,"']'","'^'",null,null,null,null,null,null,null,null,null,null,
-        null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
-        null,null,"'{'","'|'","'}'","'~'",null,null,null,null,null,null,null,null,null,
-        null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
-        null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
-        null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
-        null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
-        null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
-        null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
-        null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
-        null,null,null,null,null,null,null,null,null,"LiteralInteger","LiteralFloat64",
-        "LiteralChar","LiteralString","LiteralTwine","ID","VerbAssign","QuasiOpen",
-        "QuasiClose","DollarIdent","AtIdent","DollarOpen","AtOpen","URI","URIStart",
-        "BodyStartWord","BodyNextWord","VTableStartWord","VTableNextWord","BIND",
-        "CATCH","CLASS","DEF","DELEGATE","ELSE","ESCAPE","FINALLY","FOR","IF","IN",
-        "MATCH","META","PRAGMA","SWITCH","THUNK","TO","TRY","VAR","WHEN","WHILE","_",
-        "DEFINE","ON","SELECT","TYPEDEF","ABSTRACT","AN","AS","ATTRIBUTE","BE","BEGIN",
-        "BEHALF","BELIEF","BELIEVE","BELIEVES","CASE","CONST","CONSTRUCTOR","CONTEXT",
-        "DECLARE","DEFAULT","DEFMACRO","DEPRECATED","DISPATCH","DO","ENCAPSULATE",
-        "ENCAPSULATED","ENCAPSULATES","END","ENSURE","ENUM","EVENTUAL","EVENTUALLY",
-        "EXPORT","EXTENDS","FACET","FORALL","FUNCTION","GIVEN","HIDDEN","HIDES",
-        "IMPLEMENTS","INTERFACE","IS","KNOW","KNOWS","LAMBDA","LET","METHOD","METHODS",
-        "MODULE","NAMESPACE","NATIVE","OBEYS","OCTET","ONEWAY","PACKAGE","PRIVATE",
-        "PROTECTED","PUBLIC","RAISES","RELIANCE","RELIANT","RELIES","RELY","REVEAL",
-        "SAKE","SIGNED","STATIC","STRUCT","SUCHTHAT","SUPPORTS","SUSPECT","SUSPECTS",
-        "SYNCHRONIZED","THIS","THROWS","TRANSIENT","TRUNCATABLE","UNSIGNED","UNUM",
-        "USES","USING","UTF8","UTF16","VALUETYPE","VIRTUAL","VOLATILE","WSTRING","EOL",
-        "OpLAnd","OpLOr","OpSame","OpNSame","OpButNot","OpLeq","OpABA","OpGeq","OpThru",
-        "OpTill","OpAsl","OpAsr","OpFlrDiv","OpMod","OpPow","OpAss","OpAssAdd",
-        "OpAssAnd","OpAssAprxDiv","OpAssFlrDiv","OpAssAsl","OpAssAsr","OpAssRemdr",
-        "OpAssMod","OpAssMul","OpAssOr","OpAssPow","OpAssSub","OpAssXor","Send",
-        "OpWhen","MapsTo","MatchBind","MisMatch","Audit",
-    };
-
-    final static String yyrule[] = {
-        "$accept : start",
-        "start : br",
-        "start : topExpr",
-        "start : MatchBind pattern",
-        "define : DEF",
-        "define : DEFINE",
-        "topExpr : br topSeqs br",
-        "eExpr : br seqs br",
-        "topSeqs : topSeq",
-        "topSeqs : topSeqs EOLs topSeq",
-        "seqs : seq",
-        "seqs : seqs EOLs seq",
-        "topSeq : seq",
-        "seq : assigns",
-        "seq : assigns ';'",
-        "assigns : assign",
-        "assigns : assigns ';' assign",
-        "assigns : define noun",
-        "nAssign : assign",
-        "nAssign : plural",
-        "assign : cond",
-        "assign : cond OpAss assign",
-        "assign : cond assignop nAssign",
-        "assign : cond OpAssAsr assign",
-        "assign : cond VerbAssign parenArgs",
-        "assign : define pattern OpAss assign",
-        "assign : binder OpAss assign",
-        "assign : varNamer OpAss assign",
-        "cond : condAnd",
-        "cond : cond OpLOr condAnd",
-        "condAnd : comp",
-        "condAnd : condAnd OpLAnd comp",
-        "comp : order",
-        "comp : order OpSame order",
-        "comp : order OpNSame order",
-        "comp : order '&' nOrder",
-        "comp : order '|' nOrder",
-        "comp : order '^' nOrder",
-        "comp : order OpButNot nOrder",
-        "comp : order MatchBind pattern",
-        "comp : order MisMatch pattern",
-        "nOrder : order",
-        "nOrder : plural",
-        "order : interval",
-        "order : interval '<' interval",
-        "order : interval OpLeq interval",
-        "order : interval OpABA interval",
-        "order : interval OpGeq interval",
-        "order : interval '>' interval",
-        "interval : shift",
-        "interval : shift OpThru shift",
-        "interval : shift OpTill shift",
-        "shift : add",
-        "shift : shift OpAsl nAdd",
-        "shift : shift OpAsr add",
-        "nAdd : add",
-        "nAdd : plural",
-        "add : mult",
-        "add : add '+' nMult",
-        "add : add '-' nMult",
-        "nMult : mult",
-        "nMult : plural",
-        "mult : pow",
-        "mult : mult '*' nPow",
-        "mult : mult '/' nPow",
-        "mult : mult OpFlrDiv nPow",
-        "mult : mult '%' nPow",
-        "mult : mult OpMod nPow",
-        "nPow : pow",
-        "nPow : plural",
-        "pow : prefix",
-        "pow : prefix OpPow nPrefix",
-        "nPrefix : prefix",
-        "nPrefix : plural",
-        "prefix : postfix",
-        "prefix : '!' prim",
-        "prefix : '~' prim",
-        "prefix : '-' prim",
-        "prefix : '&' noun",
-        "postfix : call",
-        "postfix : metaExpr",
-        "postfix : postfix '[' argList ']'",
-        "postfix : postfix Send verb parenArgs",
-        "postfix : postfix Send parenArgs",
-        "postfix : postfix Send verb",
-        "postfix : postfix verb",
-        "postfix : postfix '.' ident",
-        "postfix : postfix '.' ident parenArgs",
-        "metaExpr : metaoid parenArgs",
-        "metaExpr : metaoid verb parenArgs",
-        "metaExpr : metaoid Send parenArgs",
-        "metaExpr : metaoid Send verb parenArgs",
-        "metaExpr : metaoid verb",
-        "metaExpr : metaoid Send verb",
-        "call : prim",
-        "call : call parenArgs",
-        "call : postfix verb parenArgs",
-        "prim : LiteralInteger",
-        "prim : LiteralFloat64",
-        "prim : LiteralChar",
-        "prim : LiteralString",
-        "prim : LiteralTwine",
-        "prim : nounExpr",
-        "prim : URI",
-        "prim : URIStart add '>'",
-        "prim : quasiParser quasiExpr",
-        "prim : parenExpr",
-        "prim : '[' argList ']'",
-        "prim : '[' maps ']'",
-        "prim : begin body",
-        "prim : begin ESCAPE pattern body",
-        "prim : begin WHILE parenExpr body",
-        "prim : begin SWITCH parenExpr caseList end",
-        "prim : begin TRY body catchList finallyClause",
-        "prim : forExpr",
-        "prim : whenExpr",
-        "prim : ifExpr",
-        "prim : macro",
-        "prim : DollarOpen LiteralInteger '}'",
-        "prim : '$' LiteralInteger",
-        "prim : '$' '$'",
-        "prim : AtOpen LiteralInteger '}'",
-        "prim : '@' LiteralInteger",
-        "prim : SELECT parenExpr caseList",
-        "prim : TYPEDEF oType",
-        "prim : object",
-        "object : defAudits vTable",
-        "object : defAudits begin funcHead body",
-        "object : begin THUNK body",
-        "object : CLASS classHead body",
-        "object : begin _ funcHead body",
-        "object : begin _ body",
-        "nounExpr : noun",
-        "parenExpr : '(' eExpr ')'",
-        "ifExpr : begin IF parenExpr body",
-        "ifExpr : begin IF parenExpr body ELSE ifExpr",
-        "ifExpr : begin IF parenExpr body ELSE begin body",
-        "forExpr : begin FOR iterPattern IN assign begin body end",
-        "whenExpr : WHEN whenHead body catches finallyClause",
-        "macro : BodyStartWord begin macroArg body restMacro",
-        "macro : VTableStartWord begin macroArg vTable end restMacro",
-        "$$1 :",
-        "restMacro : $$1 BodyNextWord begin macroArg body restMacro",
-        "restMacro : VTableNextWord begin macroArg vTable end restMacro",
-        "macroArg :",
-        "macroArg : parenExpr",
-        "macroArg : pattern",
-        "quasiParser :",
-        "quasiParser : ident",
-        "quasiParser : '(' eExpr ')'",
-        "quasiExpr : QuasiClose",
-        "quasiExpr : innerExprs QuasiClose",
-        "innerExprs : QuasiOpen innerExpr",
-        "innerExprs : innerExprs QuasiOpen innerExpr",
-        "innerExpr : DollarIdent",
-        "innerExpr : DollarOpen eExpr '}'",
-        "patternList : emptyBr",
-        "patternList : patterns br",
-        "patterns : pattern",
-        "patterns : patterns ',' br pattern",
-        "mapPatternList : mapPatterns br",
-        "mapPatterns : mapPattern",
-        "mapPatterns : mapPatterns ',' br mapPattern",
-        "iterPattern : pattern",
-        "iterPattern : mapPattern",
-        "mapPattern : pattern MapsTo pattern",
-        "mapPattern : MapsTo namer",
-        "pattern : listPatt",
-        "pattern : listPatt '?' order",
-        "pattern : metaoid parenExpr MapsTo pattern",
-        "listPatt : eqPatt",
-        "listPatt : '[' patternList ']'",
-        "listPatt : '[' patternList ']' '+' listPatt",
-        "listPatt : '[' mapPatternList ']'",
-        "listPatt : '[' mapPatternList ']' '|' listPatt",
-        "eqPatt : quasiPatt",
-        "eqPatt : OpSame prim",
-        "quasiPatt : namer",
-        "quasiPatt : quasiParser quasiPattern",
-        "quasiPattern : QuasiClose",
-        "quasiPattern : innerThings QuasiClose",
-        "innerThings : QuasiOpen innerThing",
-        "innerThings : innerThings QuasiOpen innerThing",
-        "innerThing : innerExpr",
-        "innerThing : innerPattern",
-        "innerPattern : AtIdent",
-        "innerPattern : AtOpen pattern '}'",
-        "namer : noun ':' order",
-        "namer : noun",
-        "namer : '&' noun",
-        "namer : _",
-        "namer : _ ':' order",
-        "namer : binder",
-        "namer : varNamer",
-        "namer : DollarOpen LiteralInteger '}'",
-        "namer : AtOpen LiteralInteger '}'",
-        "binder : BIND noun ':' order",
-        "binder : BIND noun",
-        "varNamer : VAR noun ':' order",
-        "varNamer : VAR noun",
-        "oName : noun",
-        "oName : _",
-        "oName : BIND noun",
-        "oName : VAR noun",
-        "oName : DollarOpen LiteralInteger '}'",
-        "oName : AtOpen LiteralInteger '}'",
-        "oName : litString",
-        "defName : define oName",
-        "defName : BIND noun",
-        "defName : VAR noun",
-        "audits : oName",
-        "audits : oName Audit nounExprs",
-        "defAudits : defName",
-        "defAudits : defName Audit nounExprs",
-        "nounExprs : nounExpr",
-        "nounExprs : nounExprs ',' br nounExpr",
-        "plural : '(' ')'",
-        "plural : '(' eExpr ',' args ')'",
-        "litString : LiteralString",
-        "litString : LiteralTwine",
-        "method : begin TO methHead body",
-        "method : begin TO verb OpAss assign end",
-        "method : begin ON methHead body",
-        "method : begin META parenExpr MapsTo parenExpr end",
-        "method : begin META parenExpr body",
-        "methHead : '(' patternList ')' resultGuard",
-        "methHead : verb '(' patternList ')' resultGuard",
-        "methHead : verb resultGuard",
-        "funcHead : '(' patternList ')' resultGuard",
-        "funcHead : verb '(' patternList ')' resultGuard",
-        "funcHead : verb resultGuard",
-        "classHead : audits begin '(' patternList ')' resultGuard",
-        "matcher : begin MATCH pattern body",
-        "delegator : begin DELEGATE body",
-        "resultGuard :",
-        "resultGuard : ':' order",
-        "whenArgs : '(' args ')'",
-        "whenHead : whenArgs OpWhen audits begin '(' patterns ')' resultGuard",
-        "whenHead : audits begin '(' whenClauses ')' resultGuard",
-        "whenClauses : whenClause",
-        "whenClauses : whenClauses ',' whenClause",
-        "whenClause : eExpr OpWhen pattern",
-        "br :",
-        "br : EOLs",
-        "EOLs : EOL",
-        "EOLs : EOLs EOL",
-        "emptyList :",
-        "emptyBr : br",
-        "parenArgs : '(' argList ')'",
-        "parenArgs : parenArgs object",
-        "argList : emptyBr",
-        "argList : args",
-        "args : eExpr",
-        "args : args ',' eExpr",
-        "maps : map",
-        "maps : maps ',' map",
-        "map : eExpr MapsTo eExpr",
-        "map : MapsTo nounExpr",
-        "verb : ident",
-        "noun : ident",
-        "ident : ID",
-        "ident : reserved",
-        "assignop : OpAssAdd",
-        "assignop : OpAssAnd",
-        "assignop : OpAssAprxDiv",
-        "assignop : OpAssFlrDiv",
-        "assignop : OpAssAsl",
-        "assignop : OpAssRemdr",
-        "assignop : OpAssMod",
-        "assignop : OpAssMul",
-        "assignop : OpAssOr",
-        "assignop : OpAssPow",
-        "assignop : OpAssSub",
-        "assignop : OpAssXor",
-        "body : '{' br '}' end",
-        "body : '{' br seqs br '}' end",
-        "caseList : '{' br matchList '}'",
-        "vTable : '{' br methodList vMatchList '}'",
-        "vTable : matcher",
-        "vTable : delegator",
-        "methodList : emptyList",
-        "methodList : methodList method br",
-        "vMatchList : matchList",
-        "vMatchList : matchList delegator br",
-        "matchList : emptyList",
-        "matchList : matchList matcher br",
-        "catchList : emptyList",
-        "catchList : catches",
-        "catches : catchList catchClause",
-        "catchClause : begin CATCH pattern body",
-        "finallyClause :",
-        "finallyClause : begin FINALLY body",
-        "oType : audits '{' br messageList '}'",
-        "oType : audits mType EOL",
-        "messageList : emptyList",
-        "messageList : DELEGATE br",
-        "messageList : messages br",
-        "messageList : messages EOLs DELEGATE br",
-        "messages : TO mType",
-        "messages : messages EOLs TO mType",
-        "messages : ON mType",
-        "messages : messages EOLs ON mType",
-        "mType : verb optType",
-        "mType : verb '(' pTypeList ')' optType",
-        "mType : '(' pTypeList ')' optType",
-        "pTypeList : br emptyList",
-        "pTypeList : br pTypes br",
-        "pTypes : pType",
-        "pTypes : pTypes ',' br pType",
-        "pType : noun optType",
-        "pType : _ optType",
-        "optType :",
-        "optType : ':' nounExpr",
-        "metaoid : META",
-        "metaoid : PRAGMA",
-        "begin :",
-        "end :",
-        "reserved : ABSTRACT",
-        "reserved : AN",
-        "reserved : AS",
-        "reserved : ATTRIBUTE",
-        "reserved : BE",
-        "reserved : BEGIN",
-        "reserved : BEHALF",
-        "reserved : BELIEF",
-        "reserved : BELIEVE",
-        "reserved : BELIEVES",
-        "reserved : CASE",
-        "reserved : CONST",
-        "reserved : CONSTRUCTOR",
-        "reserved : CONTEXT",
-        "reserved : DECLARE",
-        "reserved : DEFAULT",
-        "reserved : DEFMACRO",
-        "reserved : DEPRECATED",
-        "reserved : DISPATCH",
-        "reserved : DO",
-        "reserved : ENCAPSULATE",
-        "reserved : ENCAPSULATED",
-        "reserved : ENCAPSULATES",
-        "reserved : END",
-        "reserved : ENSURE",
-        "reserved : ENUM",
-        "reserved : EVENTUAL",
-        "reserved : EVENTUALLY",
-        "reserved : EXPORT",
-        "reserved : EXTENDS",
-        "reserved : FACET",
-        "reserved : FORALL",
-        "reserved : FUNCTION",
-        "reserved : GIVEN",
-        "reserved : HIDDEN",
-        "reserved : HIDES",
-        "reserved : IMPLEMENTS",
-        "reserved : INTERFACE",
-        "reserved : IS",
-        "reserved : KNOW",
-        "reserved : KNOWS",
-        "reserved : LAMBDA",
-        "reserved : LET",
-        "reserved : METHOD",
-        "reserved : METHODS",
-        "reserved : MODULE",
-        "reserved : NAMESPACE",
-        "reserved : NATIVE",
-        "reserved : OBEYS",
-        "reserved : OCTET",
-        "reserved : ONEWAY",
-        "reserved : PACKAGE",
-        "reserved : PRIVATE",
-        "reserved : PROTECTED",
-        "reserved : PUBLIC",
-        "reserved : RAISES",
-        "reserved : RELIANCE",
-        "reserved : RELIANT",
-        "reserved : RELIES",
-        "reserved : RELY",
-        "reserved : REVEAL",
-        "reserved : SAKE",
-        "reserved : SIGNED",
-        "reserved : STATIC",
-        "reserved : STRUCT",
-        "reserved : SUCHTHAT",
-        "reserved : SUPPORTS",
-        "reserved : SUSPECT",
-        "reserved : SUSPECTS",
-        "reserved : SYNCHRONIZED",
-        "reserved : THIS",
-        "reserved : THROWS",
-        "reserved : TRANSIENT",
-        "reserved : TRUNCATABLE",
-        "reserved : UNSIGNED",
-        "reserved : UNUM",
-        "reserved : USES",
-        "reserved : USING",
-        "reserved : UTF8",
-        "reserved : UTF16",
-        "reserved : VALUETYPE",
-        "reserved : VIRTUAL",
-        "reserved : VOLATILE",
-        "reserved : WSTRING",
-    };
-
-//#line 1183 "e.y"
-
-    /**
-     *
-     */
-    static public final StaticMaker EParserMaker =
-      StaticMaker.make(EParser.class);
-
-    /**
-     * caches previous simple parses (as is used for quasi-parsing)
-     */
-    static private IdentityCacheTable OurCache =
-      new IdentityCacheTable(ENode.class, 100);
-
-    /**
-     *
-     */
-    static private final ConstMap DefaultProps =
-      ConstMap.fromProperties(System.getProperties());
-
-
-    /** contains all the tokens after yylval */
-    private ELexer myLexer;
-
-    /**
-     * Do we escape after parsing only one expression, or do we parse the
-     * entire input?
-     */
-    private boolean myOnlyOneExprFlag;
-
-    /** how we exit yacc logic */
-    private Ejector myEscape;
-
-
-    /**
-     *
-     */
-    public EParser(ELexer lexer) {
-        this(DefaultProps, lexer, false, false);
-    }
+/**
+ *
+ */
+public EParser(ConstMap props,
+               ELexer lexer,
+               boolean debugFlag,
+               boolean onlyOneExprFlag)
+{
+    super(props); //XXX must really be props
+    initTables();
+    myLexer = lexer;
+    yydebug = debugFlag;
+    myOnlyOneExprFlag = onlyOneExprFlag;
+    myEscape = new Ejector();
+}
 
-    /**
-     *
-     */
-    public EParser(ConstMap props, ELexer lexer) {
-        this(props, lexer, false, false);
-    }
+/**
+ * For use as from E as a quasi-literal parser.
+ *
+ * @param sourceCode The source code itself, not the location of
+ * the source code
+ */
+static public ENode valueMaker(Twine sourceCode) {
+    return run(sourceCode, true);
+}
 
-    /**
-     *
-     */
-    public EParser(ConstMap props,
-                   ELexer lexer,
-                   boolean debugFlag,
-                   boolean onlyOneExprFlag) {
-        super(props); //XXX must really be props
-        initTables();
-        myLexer = lexer;
-        yydebug = debugFlag;
-        myOnlyOneExprFlag = onlyOneExprFlag;
-        myEscape = new Ejector();
-    }
+/**
+ * For use from E as a quasi-pattern parser.
+ *
+ * @param sourceCode The source code itself, not the location of
+ * the source code
+ */
+static public ENode matchMaker(Twine sourceCode) {
+    return run(sourceCode, true);
+}
 
-    /**
-     * For use as from E as a quasi-literal parser.
-     *
-     * @param sourceCode The source code itself, not the location of
-     * the source code
-     */
-    static public ENode valueMaker(Twine sourceCode) {
-        return run(sourceCode, true);
-    }
 
-    /**
-     * For use from E as a quasi-pattern parser.
-     *
-     * @param sourceCode The source code itself, not the location of
-     * the source code
-     */
-    static public ENode matchMaker(Twine sourceCode) {
-        return run(sourceCode, true);
-    }
+/**
+ * For simple string -> expression parsing, especially for use from E
+ *
+ * @param sourceCode The source code itself, not the location of
+ * the source code
+ */
+static public ENode run(Twine sourceCode) {
+    return run(sourceCode, false);
+}
 
+/**
+ *
+ */
+static public ENode run(Twine sourceCode, boolean quasiFlag) {
+    return run(sourceCode, quasiFlag, DefaultProps);
+}
 
-    /**
-     * For simple string -> expression parsing, especially for use from E
-     *
-     * @param sourceCode The source code itself, not the location of
-     * the source code
-     */
-    static public ENode run(Twine sourceCode) {
-        return run(sourceCode, false);
-    }
+/**
+ *
+ */
+static public ENode run(Twine sourceCode, boolean quasiFlag, ConstMap props) {
+    ENode result = (ENode)OurCache.get(sourceCode, null);
+    if (null == result) {
+        try {
+            ELexer lexer = ELexer.make(sourceCode,
+                                       quasiFlag,
+                                       Interp.testProp(props,
+                                                       "e.enable.notabs"));
+            EParser parser = new EParser(props, lexer, false, false);
+            result = parser.parse();
 
-    /**
-     *
-     */
-    static public ENode run(Twine sourceCode, boolean quasiFlag) {
-        return run(sourceCode, quasiFlag, DefaultProps);
+        } catch (IOException iox) {
+            throw ThrowableSugar.backtrace(iox, "parsing a string?!");
+        }
+        OurCache.put(sourceCode, result);
     }
-
-    /**
-     *
-     */
-    static public ENode run(Twine sourceCode, boolean quasiFlag, ConstMap props) {
-        ENode result = (ENode)OurCache.get(sourceCode, null);
-        if (null == result) {
-            try {
-                ELexer lexer = ELexer.make(sourceCode,
-                                           quasiFlag,
-                                           Interp.testProp(props,
-                                                           "e.enable.notabs"));
-                EParser parser = new EParser(props, lexer, false, false);
-                result = parser.parse();
+    return result;
+}
 
-            } catch (IOException iox) {
-                throw ThrowableSugar.backtrace(iox, "parsing a string?!");
-            }
-            OurCache.put(sourceCode, result);
-        }
+/**
+ * If the input is empty, returns the null expression e`null`, rather
+ * than null. 
+ */
+public ENode parse() {
+    ENode result = optParse();
+    if (result == null) {
+        return NULL;
+    } else {
         return result;
     }
+}
 
-    /**
-     * If the input is empty, returns the null expression e`null`, rather
-     * than null.
-     */
-    public ENode parse() {
-        ENode result = optParse();
-        if (result == null) {
-            return NULL;
+/**
+ *
+ */
+public ENode optParse() {
+    try {
+        if (yyparse() == 0) {
+            yyerror("internal: success should eject rather than return");
         } else {
-            return result;
+            yyerror("couldn't parse expression");
         }
+    } catch (Throwable t) {
+        return (ENode)myEscape.result(t);
+    } finally {
+        myEscape.disable();
     }
+    return null; //keep the compiler happy
+}
 
-    /**
-     *
-     */
-    public ENode optParse() {
-        try {
-            if (yyparse() == 0) {
-                yyerror("internal: success should eject rather than return");
-            } else {
-                yyerror("couldn't parse expression");
-            }
-        } catch (Throwable t) {
-            return (ENode)myEscape.result(t);
-        } finally {
-            myEscape.disable();
-        }
-        return null; //keep the compiler happy
+/**
+ *
+ */
+private Object oneExpr(Object expr) {
+    if (myOnlyOneExprFlag) {
+        myEscape.run(expr);
     }
+    return expr;
+}
 
-    /**
-     *
-     */
-    private Object oneExpr(Object expr) {
-        if (myOnlyOneExprFlag) {
-            myEscape.run(expr);
-        }
-        return expr;
+/**
+ *
+ */
+private int yylex() {
+    AstroToken token = null;
+    try {
+        token = myLexer.nextToken();
+    } catch (IOException ex) {
+        yyerror("io: " + ex);
     }
-
-    /**
-     *
-     */
-    private int yylex() {
-        AstroToken token = null;
-        try {
-            token = myLexer.nextToken();
-        } catch (IOException ex) {
-            yyerror("io: " + ex);
-        }
-        yylval = token;
-        return token.getType();
-    }
+    yylval = token;
+    return token.getType();
+}
 
-    /**
-     *
-     */
-    private void yyerror(String s) throws SyntaxException {
-        int ttype = ((AstroToken)yylval).getType();
-        if (EParser.EOFTOK == ttype && "syntax error".equals(s)) {
-            myLexer.needMore("Unexpected EOF");
-        } else {
-            syntaxError(s);
-        }
+/**
+ *
+ */
+private void yyerror(String s) throws SyntaxException {
+    int ttype = ((AstroToken)yylval).getType();
+    if (EParser.EOFTOK == ttype && "syntax error".equals(s)) {
+        myLexer.needMore("Unexpected EOF");
+    } else {
+        syntaxError(s);
     }
+}
 
-    /**
-     *
-     */
-    public void setSource(Twine newSource) {
-        myLexer.setSource(newSource);
-    }
+/**
+ *
+ */
+public void setSource(Twine newSource) {
+    myLexer.setSource(newSource);
+}
 
-    /**
-     *
-     */
-    public boolean isEndOfFile() {
-        return myLexer.isEndOfFile();
-    }
+/**
+ *
+ */
+public boolean isEndOfFile() {
+    return myLexer.isEndOfFile();
+}
 
-    /**
-     * Overrides syntaxError in EBuilder
-     */
-    /*package*/
-    void syntaxError(String msg) throws SyntaxException {
-        myLexer.syntaxError(msg);
-    }
+/**
+ * Overrides syntaxError in EBuilder
+ */
+/*package*/ void syntaxError(String msg) throws SyntaxException {
+    myLexer.syntaxError(msg);
+}
 
 
-    /**
-     *
-     */
-    private boolean isTokenKind(Object tok, int[] members) {
-        if (!(tok instanceof AstroToken)) {
-            return false;
-        }
-        int ttype = ((AstroToken)tok).getType();
-        for (int i = 0; i < members.length; i++) {
-            if (ttype == members[i]) {
-                return true;
-            }
-        }
+/**
+ *
+ */
+private boolean isTokenKind(Object tok, int[] members) {
+    if (! (tok instanceof AstroToken)) {
         return false;
     }
-
-    static private final int[] LiteralTypes = {
-        LiteralInteger,
-        LiteralFloat64,
-        LiteralChar,
-        LiteralString,
-        LiteralTwine
-    };
-
-    /**
-     *
-     */
-    /*package*/
-    boolean isLiteralToken(Object tok) {
-        return isTokenKind(tok, LiteralTypes);
-    }
-
-    static private final int[] QuasiTypes = {
-        QuasiOpen,
-        QuasiClose
-    };
-
-    /**
-     *
-     */
-    /*package*/
-    boolean isQuasiPart(Object tok) {
-        return isTokenKind(tok, QuasiTypes);
+    int ttype = ((AstroToken)tok).getType();
+    for (int i = 0; i < members.length; i++) {
+        if (ttype == members[i]) {
+            return true;
+        }
     }
-
-
-    /*********************************/
+    return false;
+}
 
+static private final int[] LiteralTypes = {
+    LiteralInteger,
+    LiteralFloat64,
+    LiteralChar,
+    LiteralString,
+    LiteralTwine
+};
+
+/**
+ *
+ */
+/*package*/ boolean isLiteralToken(Object tok) {
+    return isTokenKind(tok, LiteralTypes);
+}
 
-    /**
-     *
-     */
-    static private String[] TheTokens = new String[yyname.length];
-
-    /** Not provided for us */
-    static /*package*/ final short EOFTOK = 0;
-
-    /**
-     * For all the names below, if the name == name.toLowerCase(), then
-     * the name must be a keyword.  Else it must not be a keyword.  The
-     * names themselves must be legal Functor identifiers.
-     */
-    static {
-        System.arraycopy(yyname, 0, TheTokens, 0, yyname.length);
-
-        TheTokens[EOFTOK] = "EOFTOK";
-        /* The magical end-of-line token, not considered whitespace */
-        TheTokens[EOL] = "EOL";
-
-        TheTokens[LiteralInteger] = "LiteralInteger";
-        TheTokens[LiteralFloat64] = "LiteralFloat64";
-        TheTokens[LiteralChar] = "LiteralChar";
-        TheTokens[LiteralString] = "LiteralString";
-        TheTokens[LiteralTwine] = "LiteralTwine";
-
-        TheTokens[ID] = "ID";
-        TheTokens[VerbAssign] = "VerbAssign";
-        TheTokens[QuasiOpen] = "QuasiOpen";
-        TheTokens[QuasiClose] = "QuasiClose";
-        TheTokens[DollarIdent] = "DollarIdent";
-        TheTokens[AtIdent] = "AtIdent";
-        TheTokens[DollarOpen] = "DollarOpen";
-        TheTokens[AtOpen] = "AtOpen";
-        TheTokens[URI] = "URI";
-        TheTokens[URIStart] = "URIStart";
-        TheTokens[BodyStartWord] = "BodyStartWord";
-        TheTokens[BodyNextWord] = "BodyNextWord";
-        TheTokens[VTableStartWord] = "VTableStartWord";
-        TheTokens[VTableNextWord] = "VTableNextWord";
-
-        /* Keywords */
-        TheTokens[BIND] = "bind";
-        TheTokens[CATCH] = "catch";
-        TheTokens[CLASS] = "class";
-        TheTokens[DEF] = "def";
-        TheTokens[DELEGATE] = "delegate";
-        TheTokens[ELSE] = "else";
-        TheTokens[ESCAPE] = "escape";
-        TheTokens[FINALLY] = "finally";
-        TheTokens[FOR] = "for";
-        TheTokens[IF] = "if";
-        TheTokens[IN] = "in";
-        TheTokens[MATCH] = "match";
-        TheTokens[META] = "meta";
-        TheTokens[PRAGMA] = "pragma";
-        TheTokens[SWITCH] = "switch";
-        TheTokens[THUNK] = "thunk";
-        TheTokens[TO] = "to";
-        TheTokens[TRY] = "try";
-        TheTokens[VAR] = "var";
-        TheTokens[WHEN] = "when";
-        TheTokens[WHILE] = "while";
-        TheTokens[_] = "_";
-
-        /* pseudo-reserved keywords */
-        TheTokens[DEFINE] = "define";
-        TheTokens[ON] = "on";
-        TheTokens[SELECT] = "select";
-        TheTokens[TYPEDEF] = "typedef";
-
-        /* reserved keywords */
-        TheTokens[ABSTRACT] = "abstract";
-        TheTokens[AN] = "an";
-        TheTokens[AS] = "as";
-        TheTokens[ATTRIBUTE] = "attribute";
-        TheTokens[BE] = "be";
-        TheTokens[BEGIN] = "begin";
-        TheTokens[BEHALF] = "behalf";
-        TheTokens[BELIEF] = "belief";
-        TheTokens[BELIEVE] = "believe";
-        TheTokens[BELIEVES] = "believes";
-        TheTokens[CASE] = "case";
-        TheTokens[CONST] = "const";
-        TheTokens[CONSTRUCTOR] = "constructor";
-        TheTokens[CONTEXT] = "context";
-        TheTokens[DECLARE] = "declare";
-        TheTokens[DEFAULT] = "default";
-        TheTokens[DEFMACRO] = "defmacro";
-        TheTokens[DEPRECATED] = "deprecated";
-        TheTokens[DISPATCH] = "dispatch";
-        TheTokens[DO] = "do";
-        TheTokens[ENCAPSULATE] = "encapsulate";
-        TheTokens[ENCAPSULATED] = "encapsulated";
-        TheTokens[ENCAPSULATES] = "encapsulates";
-        TheTokens[END] = "end";
-        TheTokens[ENSURE] = "ensure";
-        TheTokens[ENUM] = "enum";
-        TheTokens[EVENTUAL] = "eventual";
-        TheTokens[EVENTUALLY] = "eventually";
-        TheTokens[EXPORT] = "export";
-        TheTokens[EXTENDS] = "extends";
-        TheTokens[FACET] = "facet";
-        TheTokens[FORALL] = "forall";
-        TheTokens[FUNCTION] = "function";
-        TheTokens[GIVEN] = "given";
-        TheTokens[HIDDEN] = "hidden";
-        TheTokens[HIDES] = "hides";
-        TheTokens[IMPLEMENTS] = "implements";
-        TheTokens[INTERFACE] = "interface";
-        TheTokens[IS] = "is";
-        TheTokens[KNOW] = "know";
-        TheTokens[KNOWS] = "knows";
-        TheTokens[LAMBDA] = "lambda";
-        TheTokens[LET] = "let";
-        TheTokens[METHOD] = "method";
-        TheTokens[METHODS] = "methods";
-        TheTokens[MODULE] = "module";
-        TheTokens[NAMESPACE] = "namespace";
-        TheTokens[NATIVE] = "native";
-        TheTokens[OBEYS] = "obeys";
-        TheTokens[OCTET] = "octet";
-        TheTokens[ONEWAY] = "oneway";
-        TheTokens[PACKAGE] = "package";
-        TheTokens[PRIVATE] = "private";
-        TheTokens[PROTECTED] = "protected";
-        TheTokens[PUBLIC] = "public";
-        TheTokens[RAISES] = "raises";
-        TheTokens[RELIANCE] = "reliance";
-        TheTokens[RELIANT] = "reliant";
-        TheTokens[RELIES] = "relies";
-        TheTokens[RELY] = "rely";
-        TheTokens[REVEAL] = "reveal";
-        TheTokens[SAKE] = "sake";
-        TheTokens[SIGNED] = "signed";
-        TheTokens[STATIC] = "static";
-        TheTokens[STRUCT] = "struct";
-        TheTokens[SUCHTHAT] = "suchthat";
-        TheTokens[SUPPORTS] = "supports";
-        TheTokens[SUSPECT] = "suspect";
-        TheTokens[SUSPECTS] = "suspects";
-        TheTokens[SYNCHRONIZED] = "synchronized";
-        TheTokens[THIS] = "this";
-        TheTokens[THROWS] = "throws";
-        TheTokens[TRANSIENT] = "transient";
-        TheTokens[TRUNCATABLE] = "truncatable";
-        TheTokens[UNSIGNED] = "unsigned";
-        TheTokens[UNUM] = "unum";
-        TheTokens[USES] = "uses";
-        TheTokens[USING] = "using";
-        TheTokens[UTF8] = "utf8";
-        TheTokens[UTF16] = "utf16";
-        TheTokens[VALUETYPE] = "valuetype";
-        TheTokens[VIRTUAL] = "virtual";
-        TheTokens[VOLATILE] = "volatile";
-        TheTokens[WSTRING] = "wstring";
-
-        /* Multi-Character Operators */
-        TheTokens[OpLAnd] = "OpLAnd";
-        TheTokens[OpLOr] = "OpLOr";
-        TheTokens[OpSame] = "OpSame";
-        TheTokens[OpNSame] = "OpNSame";
-        TheTokens[OpButNot] = "OpButNot";
-        TheTokens[OpLeq] = "OpLeq";
-        TheTokens[OpABA] = "OpABA";
-        TheTokens[OpGeq] = "OpGeq";
-        TheTokens[OpThru] = "OpThru";
-        TheTokens[OpTill] = "OpTill";
-        TheTokens[OpAsl] = "OpAsl";
-        TheTokens[OpAsr] = "OpAsr";
-        TheTokens[OpFlrDiv] = "OpFlrDiv";
-        TheTokens[OpMod] = "OpMod";
-        TheTokens[OpPow] = "OpPow";
-
-        TheTokens[OpAss] = "OpAss";
-        TheTokens[OpAssAdd] = "OpAssAdd";
-        TheTokens[OpAssAnd] = "OpAssAnd";
-        TheTokens[OpAssAprxDiv] = "OpAssAprxDiv";
-        TheTokens[OpAssFlrDiv] = "OpAssFlrDiv";
-        TheTokens[OpAssAsl] = "OpAssAsl";
-        TheTokens[OpAssAsr] = "OpAssAsr";
-        TheTokens[OpAssRemdr] = "OpAssRemdr";
-        TheTokens[OpAssMod] = "OpAssMod";
-        TheTokens[OpAssMul] = "OpAssMul";
-        TheTokens[OpAssOr] = "OpAssOr";
-        TheTokens[OpAssPow] = "OpAssPow";
-        TheTokens[OpAssSub] = "OpAssSub";
-        TheTokens[OpAssXor] = "OpAssXor";
-
-        /* Other funky tokens */
-        TheTokens[Send] = "Send";
-        TheTokens[MapsTo] = "MapsTo";
-        TheTokens[MatchBind] = "MatchBind";
-        TheTokens[MisMatch] = "MisMatch";
-        TheTokens[Audit] = "Audit";
-    }
+static private final int[] QuasiTypes = {
+    QuasiOpen,
+    QuasiClose
+};
+
+/**
+ *
+ */
+/*package*/ boolean isQuasiPart(Object tok) {
+    return isTokenKind(tok, QuasiTypes);
+}
 
-    /**
-     *
-     */
-    static public ConstList getTokenNames() {
-        return ConstList.fromArray(TheTokens);
-    }
 
-    /**
-     *
-     */
-    static private IntTable TheTokenTable = null;
-
-    /**
-     *
-     */
-    static private IntTable getTokenTable() {
-        if (null == TheTokenTable) {
-            TheTokenTable = new IntTable(String.class);
-            for (int i = 0; i < TheTokens.length; i++) {
-                if (TheTokens[i] != null) {
-                    TheTokenTable.putInt(TheTokens[i], i, true);
-                }
-            }
-        }
-        return TheTokenTable;
-    }
+/*********************************/
 
-    /**
-     * If 'name' is a keyword, return it's token type code, else -1.
-     * <p>
-     * Note that E keywords are case insensitive, so 'name' is first
-     * toLowerCase()d.
-     */
-    static public int optKeywordType(String name) {
-        name = name.toLowerCase();
-        return getTokenTable().getInt(name, -1);
-    }
 
-    /**
-     *
-     */
-    static public ConstMap getTokenMap() {
-        return getTokenTable().snapshot();
-    }
-
-    /**
-     * These are the tokens that may appear at the end of a line, in which
-     * case the next line is a (to be indented) continuation of the
-     * expression.
-     * <p>
-     * Note that &gt; isn't on the list because of its role in closing a
-     * calculated URI expression.
-     */
-    static private final int[] TheContinuerOps = {
-        '!',
-        '%',
-        '&',
-        '*',
-        '+',
-        '-',
-        '/',
-        ':',
-        '<',
-        '?',
-        '^',
-        '|',
-        '~',
-        Audit,              // ::
-        MapsTo,             // =>
-        MatchBind,          // =~
-        MisMatch,           // !~
-        OpABA,              // <=>
-        OpAsl,              // <<
-        OpAsr,              // >>
-        OpAss,              // :=
-        OpAssAdd,           // +=
-        OpAssAnd,           // &=
-        OpAssAprxDiv,       // /=
-        OpAssAsl,           // <<=
-        OpAssAsr,           // >>=
-        OpAssFlrDiv,        // _/=
-        OpAssMod,           // %%=
-        OpAssMul,           // *=
-        OpAssOr,            // |=
-        OpAssPow,           // **=
-        OpAssRemdr,         // %=
-        OpAssSub,           // -=
-        OpAssXor,           // ^=
-        OpButNot,           // &!
-        OpFlrDiv,           // _/
-        OpGeq,              // >=
-        OpLAnd,             // &&
-        OpLOr,              // ||
-        OpLeq,              // <=
-        OpMod,              // %%
-        OpNSame,            // !=
-        OpPow,              // **
-        OpSame,             // ==
-        OpThru,             // ..
-        OpTill,             // ..!
-        OpWhen,             // ->
-        Send                // <-
-    };
-
-    /**
-     * TheContinuers[tokenType] says whether this is a continuation
-     * operator.
-     */
-    static private boolean[] TheContinuers = new boolean[yyname.length];
-
-    static {
-        //this initialization counts on the initial allocation
-        //initializing the members to false
+/**
+ *
+ */
+static private String[] TheTokens = new String[yyname.length];
+
+/** Not provided for us */
+static /*package*/ final short EOFTOK = 0;
+
+/**
+ * For all the names below, if the name == name.toLowerCase(), then
+ * the name must be a keyword.  Else it must not be a keyword.  The
+ * names themselves must be legal Functor identifiers.
+ */
+static {
+    System.arraycopy(yyname, 0, TheTokens, 0, yyname.length);
+
+    TheTokens[EOFTOK]           = "EOFTOK";
+    /* The magical end-of-line token, not considered whitespace */
+    TheTokens[EOL]              = "EOL";
+
+    TheTokens[LiteralInteger]   = "LiteralInteger";
+    TheTokens[LiteralFloat64]   = "LiteralFloat64";
+    TheTokens[LiteralChar]      = "LiteralChar";
+    TheTokens[LiteralString]    = "LiteralString";
+    TheTokens[LiteralTwine]     = "LiteralTwine";
+
+    TheTokens[ID]               = "ID";
+    TheTokens[VerbAssign]       = "VerbAssign";
+    TheTokens[QuasiOpen]        = "QuasiOpen";
+    TheTokens[QuasiClose]       = "QuasiClose";
+    TheTokens[DollarIdent]      = "DollarIdent";
+    TheTokens[AtIdent]          = "AtIdent";
+    TheTokens[DollarOpen]       = "DollarOpen";
+    TheTokens[AtOpen]           = "AtOpen";
+    TheTokens[URI]              = "URI";
+    TheTokens[URIStart]         = "URIStart";
+    TheTokens[BodyStartWord]    = "BodyStartWord";
+    TheTokens[BodyNextWord]     = "BodyNextWord";
+    TheTokens[VTableStartWord]  = "VTableStartWord";
+    TheTokens[VTableNextWord]   = "VTableNextWord";
+
+    /* Keywords */
+    TheTokens[BIND]             = "bind";
+    TheTokens[CATCH]            = "catch";
+    TheTokens[CLASS]            = "class";
+    TheTokens[DEF]              = "def";
+    TheTokens[DELEGATE]         = "delegate";
+    TheTokens[ELSE]             = "else";
+    TheTokens[ESCAPE]           = "escape";
+    TheTokens[FINALLY]          = "finally";
+    TheTokens[FOR]              = "for";
+    TheTokens[IF]               = "if";
+    TheTokens[IN]               = "in";
+    TheTokens[MATCH]            = "match";
+    TheTokens[META]             = "meta";
+    TheTokens[PRAGMA]           = "pragma";
+    TheTokens[SWITCH]           = "switch";
+    TheTokens[THUNK]            = "thunk";
+    TheTokens[TO]               = "to";
+    TheTokens[TRY]              = "try";
+    TheTokens[VAR]              = "var";
+    TheTokens[WHEN]             = "when";
+    TheTokens[WHILE]            = "while";
+    TheTokens[_]                = "_";
+
+    /* pseudo-reserved keywords */
+    TheTokens[DEFINE]           = "define";
+    TheTokens[ON]               = "on";
+    TheTokens[SELECT]           = "select";
+    TheTokens[TYPEDEF]          = "typedef";
+
+    /* reserved keywords */
+    TheTokens[ABSTRACT]         = "abstract";
+    TheTokens[AN]               = "an";
+    TheTokens[AS]               = "as";
+    TheTokens[ATTRIBUTE]        = "attribute";
+    TheTokens[BE]               = "be";
+    TheTokens[BEGIN]            = "begin";
+    TheTokens[BEHALF]           = "behalf";
+    TheTokens[BELIEF]           = "belief";
+    TheTokens[BELIEVE]          = "believe";
+    TheTokens[BELIEVES]         = "believes";
+    TheTokens[CASE]             = "case";
+    TheTokens[CONST]            = "const";
+    TheTokens[CONSTRUCTOR]      = "constructor";
+    TheTokens[CONTEXT]          = "context";
+    TheTokens[DECLARE]          = "declare";
+    TheTokens[DEFAULT]          = "default";
+    TheTokens[DEFMACRO]         = "defmacro";
+    TheTokens[DEPRECATED]       = "deprecated";
+    TheTokens[DISPATCH]         = "dispatch";
+    TheTokens[DO]               = "do";
+    TheTokens[ENCAPSULATE]      = "encapsulate";
+    TheTokens[ENCAPSULATED]     = "encapsulated";
+    TheTokens[ENCAPSULATES]     = "encapsulates";
+    TheTokens[END]              = "end";
+    TheTokens[ENSURE]           = "ensure";
+    TheTokens[ENUM]             = "enum";
+    TheTokens[EVENTUAL]         = "eventual";
+    TheTokens[EVENTUALLY]       = "eventually";
+    TheTokens[EXPORT]           = "export";
+    TheTokens[EXTENDS]          = "extends";
+    TheTokens[FACET]            = "facet";
+    TheTokens[FORALL]           = "forall";
+    TheTokens[FUNCTION]         = "function";
+    TheTokens[GIVEN]            = "given";
+    TheTokens[HIDDEN]           = "hidden";
+    TheTokens[HIDES]            = "hides";
+    TheTokens[IMPLEMENTS]       = "implements";
+    TheTokens[INTERFACE]        = "interface";
+    TheTokens[IS]               = "is";
+    TheTokens[KNOW]             = "know";
+    TheTokens[KNOWS]            = "knows";
+    TheTokens[LAMBDA]           = "lambda";
+    TheTokens[LET]              = "let";
+    TheTokens[METHOD]           = "method";
+    TheTokens[METHODS]          = "methods";
+    TheTokens[MODULE]           = "module";
+    TheTokens[NAMESPACE]        = "namespace";
+    TheTokens[NATIVE]           = "native";
+    TheTokens[OBEYS]            = "obeys";
+    TheTokens[OCTET]            = "octet";
+    TheTokens[ONEWAY]           = "oneway";
+    TheTokens[PACKAGE]          = "package";
+    TheTokens[PRIVATE]          = "private";
+    TheTokens[PROTECTED]        = "protected";
+    TheTokens[PUBLIC]           = "public";
+    TheTokens[RAISES]           = "raises";
+    TheTokens[RELIANCE]         = "reliance";
+    TheTokens[RELIANT]          = "reliant";
+    TheTokens[RELIES]           = "relies";
+    TheTokens[RELY]             = "rely";
+    TheTokens[REVEAL]           = "reveal";
+    TheTokens[SAKE]             = "sake";
+    TheTokens[SIGNED]           = "signed";
+    TheTokens[STATIC]           = "static";
+    TheTokens[STRUCT]           = "struct";
+    TheTokens[SUCHTHAT]         = "suchthat";
+    TheTokens[SUPPORTS]         = "supports";
+    TheTokens[SUSPECT]          = "suspect";
+    TheTokens[SUSPECTS]         = "suspects";
+    TheTokens[SYNCHRONIZED]     = "synchronized";
+    TheTokens[THIS]             = "this";
+    TheTokens[THROWS]           = "throws";
+    TheTokens[TRANSIENT]        = "transient";
+    TheTokens[TRUNCATABLE]      = "truncatable";
+    TheTokens[UNSIGNED]         = "unsigned";
+    TheTokens[UNUM]             = "unum";
+    TheTokens[USES]             = "uses";
+    TheTokens[USING]            = "using";
+    TheTokens[UTF8]             = "utf8";
+    TheTokens[UTF16]            = "utf16";
+    TheTokens[VALUETYPE]        = "valuetype";
+    TheTokens[VIRTUAL]          = "virtual";
+    TheTokens[VOLATILE]         = "volatile";
+    TheTokens[WSTRING]          = "wstring";
+
+    /* Multi-Character Operators */
+    TheTokens[OpLAnd]           = "OpLAnd";
+    TheTokens[OpLOr]            = "OpLOr";
+    TheTokens[OpSame]           = "OpSame";
+    TheTokens[OpNSame]          = "OpNSame";
+    TheTokens[OpButNot]         = "OpButNot";
+    TheTokens[OpLeq]            = "OpLeq";
+    TheTokens[OpABA]            = "OpABA";
+    TheTokens[OpGeq]            = "OpGeq";
+    TheTokens[OpThru]           = "OpThru";
+    TheTokens[OpTill]           = "OpTill";
+    TheTokens[OpAsl]            = "OpAsl";
+    TheTokens[OpAsr]            = "OpAsr";
+    TheTokens[OpFlrDiv]         = "OpFlrDiv";
+    TheTokens[OpMod]            = "OpMod";
+    TheTokens[OpPow]            = "OpPow";
+
+    TheTokens[OpAss]            = "OpAss";
+    TheTokens[OpAssAdd]         = "OpAssAdd";
+    TheTokens[OpAssAnd]         = "OpAssAnd";
+    TheTokens[OpAssAprxDiv]     = "OpAssAprxDiv";
+    TheTokens[OpAssFlrDiv]      = "OpAssFlrDiv";
+    TheTokens[OpAssAsl]         = "OpAssAsl";
+    TheTokens[OpAssAsr]         = "OpAssAsr";
+    TheTokens[OpAssRemdr]       = "OpAssRemdr";
+    TheTokens[OpAssMod]         = "OpAssMod";
+    TheTokens[OpAssMul]         = "OpAssMul";
+    TheTokens[OpAssOr]          = "OpAssOr";
+    TheTokens[OpAssPow]         = "OpAssPow";
+    TheTokens[OpAssSub]         = "OpAssSub";
+    TheTokens[OpAssXor]         = "OpAssXor";
+
+    /* Other funky tokens */
+    TheTokens[Send]             = "Send";
+    TheTokens[MapsTo]           = "MapsTo";
+    TheTokens[MatchBind]        = "MatchBind";
+    TheTokens[MisMatch]         = "MisMatch";
+    TheTokens[Audit]            = "Audit";
+}
 
-        for (int i = 0; i < TheContinuerOps.length; i++) {
-            TheContinuers[TheContinuerOps[i]] = true;
-        }
-    }
+/**
+ *
+ */
+static public final AstroSchema DEFAULT_SCHEMA =
+  new BaseSchema(ConstList.fromArray(TheTokens));
+
+/**
+ * These are the tokens that may appear at the end of a line, in which
+ * case the next line is a (to be indented) continuation of the
+ * expression. 
+ * <p>
+ * Note that &gt; isn't on the list because of its role in closing a
+ * calculated URI expression.
+ */
+static private final int[] TheContinuerOps = {
+    '!',
+    '%',
+    '&',
+    '*',
+    '+',
+    '-',
+    '/',
+    ':',
+    '<',
+    '?',
+    '^',
+    '|',
+    '~',
+    Audit,              // ::
+    MapsTo,             // =>
+    MatchBind,          // =~
+    MisMatch,           // !~
+    OpABA,              // <=>
+    OpAsl,              // <<
+    OpAsr,              // >>
+    OpAss,              // :=
+    OpAssAdd,           // +=
+    OpAssAnd,           // &=
+    OpAssAprxDiv,       // /=
+    OpAssAsl,           // <<=
+    OpAssAsr,           // >>=
+    OpAssFlrDiv,        // _/=
+    OpAssMod,           // %%=
+    OpAssMul,           // *=
+    OpAssOr,            // |=
+    OpAssPow,           // **=
+    OpAssRemdr,         // %=
+    OpAssSub,           // -=
+    OpAssXor,           // ^=
+    OpButNot,           // &!
+    OpFlrDiv,           // _/
+    OpGeq,              // >=
+    OpLAnd,             // &&
+    OpLOr,              // ||
+    OpLeq,              // <=
+    OpMod,              // %%
+    OpNSame,            // !=
+    OpPow,              // **
+    OpSame,             // ==
+    OpThru,             // ..
+    OpTill,             // ..!
+    OpWhen,             // ->
+    Send                // <-
+};
+
+/**
+ * TheContinuers[tokenType] says whether this is a continuation
+ * operator.
+ */
+static private boolean[] TheContinuers = new boolean[yyname.length];
+
+static {
+    //this initialization counts on the initial allocation
+    //initializing the members to false
 
-    /**
-     * If this token appears at the end of a line, does that make the next
-     * line a (to be indented) continuation line?
-     */
-    static public boolean isContinuer(int tokenType) {
-        return TheContinuers[tokenType];
+    for (int i = 0; i < TheContinuerOps.length; i++) {
+        TheContinuers[TheContinuerOps[i]] = true;
     }
+}
 
-    //#line 5637 "EParser.java"
+/**
+ * If this token appears at the end of a line, does that make the next
+ * line a (to be indented) continuation line?
+ */
+static public boolean isContinuer(int tokenType) {
+    return TheContinuers[tokenType];
+}
+//#line 5602 "EParser.java"
 //###############################################################
 // method: yylexdebug : check lexer state
 //###############################################################
-    void yylexdebug(int state, int ch) {
-        String s = null;
-        if (ch < 0) ch = 0;
-        if (ch <= YYMAXTOKEN) //check index bounds
-            s = yyname[ch];    //now get it
-        if (s == null)
-            s = "illegal-symbol";
-        debug("state " + state + ", reading " + ch + " (" + s + ")");
-    }
+void yylexdebug(int state,int ch)
+{
+String s=null;
+  if (ch < 0) ch=0;
+  if (ch <= YYMAXTOKEN) //check index bounds
+     s = yyname[ch];    //now get it
+  if (s==null)
+    s = "illegal-symbol";
+  debug("state "+state+", reading "+ch+" ("+s+")");
+}
+
 
 
-    //###############################################################
+//###############################################################
 // method: yyparse : parse input and execute indicated items
 //###############################################################
-    int yyparse() {
-        int yyn;       //next next thing to do
-        int yym;       //
-        int yystate;   //current parsing state from state table
-        String yys;    //current token string
-        boolean doaction;
-        init_stacks();
-        yynerrs = 0;
-        yyerrflag = 0;
-        yychar = -1;          //impossible char forces a read
-        yystate = 0;            //initial state
-        state_push(yystate);  //save it
-        while (true) //until parsing is done, either correctly, or w/error
+int yyparse() 
+{
+int yyn;       //next next thing to do
+int yym;       //
+int yystate;   //current parsing state from state table
+String yys;    //current token string
+boolean doaction;
+  init_stacks();
+  yynerrs = 0;
+  yyerrflag = 0;
+  yychar = -1;          //impossible char forces a read
+  yystate=0;            //initial state
+  state_push(yystate);  //save it
+  while (true) //until parsing is done, either correctly, or w/error
+    {
+    doaction=true;
+    if (yydebug) debug("loop"); 
+    //#### NEXT ACTION (from reduction table)
+    for (yyn=yydefred[yystate];yyn==0;yyn=yydefred[yystate])
+      {
+      if (yydebug) debug("yyn:"+yyn+"  state:"+yystate+"  char:"+yychar);
+      if (yychar < 0)      //we want a char?
         {
-            doaction = true;
-            if (yydebug) debug("loop");
-            //#### NEXT ACTION (from reduction table)
-            for (yyn = yydefred[yystate]; yyn == 0; yyn = yydefred[yystate]) {
-                if (yydebug) debug("yyn:" + yyn + "  state:" + yystate + "  char:" + yychar);
-                if (yychar < 0)      //we want a char?
-                {
-                    yychar = yylex();  //get next token
-                    //#### ERROR CHECK ####
-                    if (yychar < 0)    //it it didn't work/error
-                    {
-                        yychar = 0;      //change it to default string (no -1!)
-                        if (yydebug)
-                            yylexdebug(yystate, yychar);
-                    }
-                }//yychar<0
-                yyn = yysindex[yystate];  //get amount to shift by (shift index)
-                if ((yyn != 0) && (yyn += yychar) >= 0 &&
-                  yyn <= YYTABLESIZE && yycheck[yyn] == yychar) {
-                    if (yydebug)
-                        debug("state " + yystate + ", shifting to state " + yytable[yyn] + "");
-                    //#### NEXT STATE ####
-                    yystate = yytable[yyn];//we are in a new state
-                    state_push(yystate);   //save it
-                    val_push(yylval);      //push our lval as the input for next rule
-                    yychar = -1;           //since we have 'eaten' a token, say we need another
-                    if (yyerrflag > 0)     //have we recovered an error?
-                        --yyerrflag;        //give ourselves credit
-                    doaction = false;        //but don't process yet
-                    break;   //quit the yyn=0 loop
-                }
-
-                yyn = yyrindex[yystate];  //reduce
-                if ((yyn != 0) && (yyn += yychar) >= 0 &&
-                  yyn <= YYTABLESIZE && yycheck[yyn] == yychar) { //we reduced!
-                    if (yydebug) debug("reduce");
-                    yyn = yytable[yyn];
-                    doaction = true; //get ready to execute
-                    break;         //drop down to actions
-                } else //ERROR RECOVERY
-                {
-                    if (yyerrflag == 0) {
-                        yyerror("syntax error");
-                        yynerrs++;
-                    }
-                    if (yyerrflag < 3) //low error count?
-                    {
-                        yyerrflag = 3;
-                        while (true)   //do until break
-                        {
-                            if (stateptr < 0)   //check for under & overflow here
-                            {
-                                yyerror("stack underflow. aborting...");  //note lower case 's'
-                                return 1;
-                            }
-                            yyn = yysindex[state_peek(0)];
-                            if ((yyn != 0) && (yyn += YYERRCODE) >= 0 &&
-                              yyn <= YYTABLESIZE && yycheck[yyn] == YYERRCODE) {
-                                if (yydebug)
-                                    debug("state " + state_peek(0) + ", error recovery shifting to state " + yytable[yyn] + " ");
-                                yystate = yytable[yyn];
-                                state_push(yystate);
-                                val_push(yylval);
-                                doaction = false;
-                                break;
-                            } else {
-                                if (yydebug)
-                                    debug("error recovery discarding state " + state_peek(0) + " ");
-                                if (stateptr < 0)   //check for under & overflow here
-                                {
-                                    yyerror("Stack underflow. aborting...");  //capital 'S'
-                                    return 1;
-                                }
-                                state_pop();
-                                val_pop();
-                            }
-                        }
-                    } else            //discard this token
-                    {
-                        if (yychar == 0)
-                            return 1; //yyabort
-                        if (yydebug) {
-                            yys = null;
-                            if (yychar <= YYMAXTOKEN) yys = yyname[yychar];
-                            if (yys == null) yys = "illegal-symbol";
-                            debug("state " + yystate + ", error recovery discards token " + yychar + " (" + yys + ")");
-                        }
-                        yychar = -1;  //read another
-                    }
-                }//end error recovery
-            }//yyn=0 loop
-            if (!doaction)   //any reason not to proceed?
-                continue;      //skip action
-            yym = yylen[yyn];          //get count of terminals on rhs
+        yychar = yylex();  //get next token
+        //#### ERROR CHECK ####
+        if (yychar < 0)    //it it didn't work/error
+          {
+          yychar = 0;      //change it to default string (no -1!)
+          if (yydebug)
+            yylexdebug(yystate,yychar);
+          }
+        }//yychar<0
+      yyn = yysindex[yystate];  //get amount to shift by (shift index)
+      if ((yyn != 0) && (yyn += yychar) >= 0 &&
+          yyn <= YYTABLESIZE && yycheck[yyn] == yychar)
+        {
+        if (yydebug)
+          debug("state "+yystate+", shifting to state "+yytable[yyn]+"");
+        //#### NEXT STATE ####
+        yystate = yytable[yyn];//we are in a new state
+        state_push(yystate);   //save it
+        val_push(yylval);      //push our lval as the input for next rule
+        yychar = -1;           //since we have 'eaten' a token, say we need another
+        if (yyerrflag > 0)     //have we recovered an error?
+           --yyerrflag;        //give ourselves credit
+        doaction=false;        //but don't process yet
+        break;   //quit the yyn=0 loop
+        }
+
+    yyn = yyrindex[yystate];  //reduce
+    if ((yyn !=0 ) && (yyn += yychar) >= 0 &&
+            yyn <= YYTABLESIZE && yycheck[yyn] == yychar)
+      {   //we reduced!
+      if (yydebug) debug("reduce");
+      yyn = yytable[yyn];
+      doaction=true; //get ready to execute
+      break;         //drop down to actions
+      }
+    else //ERROR RECOVERY
+      {
+      if (yyerrflag==0)
+        {
+        yyerror("syntax error");
+        yynerrs++;
+        }
+      if (yyerrflag < 3) //low error count?
+        {
+        yyerrflag = 3;
+        while (true)   //do until break
+          {
+          if (stateptr<0)   //check for under & overflow here
+            {
+            yyerror("stack underflow. aborting...");  //note lower case 's'
+            return 1;
+            }
+          yyn = yysindex[state_peek(0)];
+          if ((yyn != 0) && (yyn += YYERRCODE) >= 0 &&
+                    yyn <= YYTABLESIZE && yycheck[yyn] == YYERRCODE)
+            {
+            if (yydebug)
+              debug("state "+state_peek(0)+", error recovery shifting to state "+yytable[yyn]+" ");
+            yystate = yytable[yyn];
+            state_push(yystate);
+            val_push(yylval);
+            doaction=false;
+            break;
+            }
+          else
+            {
             if (yydebug)
-                debug("state " + yystate + ", reducing " + yym + " by rule " + yyn + " (" + yyrule[yyn] + ")");
-            if (yym > 0)                 //if count of rhs not 'nil'
-                yyval = val_peek(yym - 1); //get current semantic value
-            switch (yyn) {
+              debug("error recovery discarding state "+state_peek(0)+" ");
+            if (stateptr<0)   //check for under & overflow here
+              {
+              yyerror("Stack underflow. aborting...");  //capital 'S'
+              return 1;
+              }
+            state_pop();
+            val_pop();
+            }
+          }
+        }
+      else            //discard this token
+        {
+        if (yychar == 0)
+          return 1; //yyabort
+        if (yydebug)
+          {
+          yys = null;
+          if (yychar <= YYMAXTOKEN) yys = yyname[yychar];
+          if (yys == null) yys = "illegal-symbol";
+          debug("state "+yystate+", error recovery discards token "+yychar+" ("+yys+")");
+          }
+        yychar = -1;  //read another
+        }
+      }//end error recovery
+    }//yyn=0 loop
+    if (!doaction)   //any reason not to proceed?
+      continue;      //skip action
+    yym = yylen[yyn];          //get count of terminals on rhs
+    if (yydebug)
+      debug("state "+yystate+", reducing "+yym+" by rule "+yyn+" ("+yyrule[yyn]+")");
+    if (yym>0)                 //if count of rhs not 'nil'
+      yyval = val_peek(yym-1); //get current semantic value
+    switch(yyn)
+      {
 //########## USER-SUPPLIED ACTIONS ##########
-                case 1:
-//#line 155 "e.y"
-                    {
-                        myEscape.run(null);
-                    }
-                    break;
-                case 2:
-//#line 156 "e.y"
-                    {
-                        myEscape.run(val_peek(0));
-                    }
-                    break;
-                case 3:
-//#line 158 "e.y"
-                    {
-                        myEscape.run(val_peek(0));
-                    }
-                    break;
-                case 5:
-//#line 166 "e.y"
-                    {
-                        pocket("define");
-                    }
-                    break;
-                case 6:
-//#line 175 "e.y"
-                    {
-                        yyval = val_peek(1);
-                    }
-                    break;
-                case 7:
+case 1:
+//#line 159 "e.y"
+{ myEscape.run(null); }
+break;
+case 2:
+//#line 160 "e.y"
+{ myEscape.run(val_peek(0)); }
+break;
+case 3:
+//#line 162 "e.y"
+{ myEscape.run(val_peek(0)); }
+break;
+case 5:
+//#line 170 "e.y"
+{ pocket("define"); }
+break;
+case 6:
 //#line 179 "e.y"
-                    {
-                        yyval = val_peek(1);
-                    }
-                    break;
-                case 9:
-//#line 190 "e.y"
-                    {
-                        yyval = sequence(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 11:
-//#line 195 "e.y"
-                    {
-                        yyval = sequence(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 12:
-//#line 203 "e.y"
-                    {
-                        yyval = oneExpr(val_peek(0));
-                    }
-                    break;
-                case 16:
-//#line 218 "e.y"
-                    {
-                        yyval = sequence(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 17:
-//#line 219 "e.y"
-                    {
-                        yyval = forward(val_peek(0));
-                    }
-                    break;
-                case 18:
-//#line 234 "e.y"
-                    {
-                        yyval = list(val_peek(0));
-                    }
-                    break;
-                case 21:
-//#line 239 "e.y"
-                    {
-                        yyval = assign(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 22:
-//#line 240 "e.y"
-                    {
-                        yyval = update(val_peek(2), val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 23:
-//#line 241 "e.y"
-                    {
-                        yyval = assAsr(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 24:
-//#line 242 "e.y"
-                    {
-                        yyval = update(val_peek(2), val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 25:
+{ yyval = val_peek(1); }
+break;
+case 7:
+//#line 183 "e.y"
+{ yyval = val_peek(1); }
+break;
+case 9:
+//#line 194 "e.y"
+{ yyval = sequence(val_peek(2), val_peek(0)); }
+break;
+case 11:
+//#line 199 "e.y"
+{ yyval = sequence(val_peek(2), val_peek(0)); }
+break;
+case 12:
+//#line 207 "e.y"
+{ yyval = oneExpr(val_peek(0)); }
+break;
+case 16:
+//#line 222 "e.y"
+{ yyval = sequence(val_peek(2), val_peek(0)); }
+break;
+case 17:
+//#line 223 "e.y"
+{ yyval = forward(val_peek(0)); }
+break;
+case 18:
+//#line 238 "e.y"
+{ yyval = list(val_peek(0)); }
+break;
+case 21:
+//#line 243 "e.y"
+{ yyval = assign(val_peek(2),     val_peek(0)); }
+break;
+case 22:
 //#line 244 "e.y"
-                    {
-                        yyval = define(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 26:
+{ yyval = update(val_peek(2), val_peek(1), val_peek(0)); }
+break;
+case 23:
 //#line 245 "e.y"
-                    {
-                        yyval = define(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 27:
+{ yyval = assAsr(val_peek(2),     val_peek(0)); }
+break;
+case 24:
 //#line 246 "e.y"
-                    {
-                        yyval = define(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 29:
-//#line 255 "e.y"
-                    {
-                        yyval = condOr(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 31:
-//#line 264 "e.y"
-                    {
-                        yyval = condAnd(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 33:
-//#line 273 "e.y"
-                    {
-                        yyval = same(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 34:
-//#line 274 "e.y"
-                    {
-                        yyval = not(same(val_peek(2), val_peek(0)));
-                    }
-                    break;
-                case 35:
-//#line 275 "e.y"
-                    {
-                        yyval = call(val_peek(2), "and", val_peek(0));
-                    }
-                    break;
-                case 36:
-//#line 276 "e.y"
-                    {
-                        yyval = call(val_peek(2), "or", val_peek(0));
-                    }
-                    break;
-                case 37:
+{ yyval = update(val_peek(2), val_peek(1), val_peek(0)); }
+break;
+case 25:
+//#line 248 "e.y"
+{ yyval = define(val_peek(2), val_peek(0)); }
+break;
+case 26:
+//#line 249 "e.y"
+{ yyval = define(val_peek(2), val_peek(0)); }
+break;
+case 27:
+//#line 250 "e.y"
+{ yyval = define(val_peek(2), val_peek(0)); }
+break;
+case 29:
+//#line 259 "e.y"
+{ yyval = condOr(val_peek(2), val_peek(0)); }
+break;
+case 31:
+//#line 268 "e.y"
+{ yyval = condAnd(val_peek(2), val_peek(0)); }
+break;
+case 33:
 //#line 277 "e.y"
-                    {
-                        yyval = call(val_peek(2), "xor", val_peek(0));
-                    }
-                    break;
-                case 38:
+{ yyval = same(val_peek(2), val_peek(0)); }
+break;
+case 34:
 //#line 278 "e.y"
-                    {
-                        yyval = call(val_peek(2), "butNot", val_peek(0));
-                    }
-                    break;
-                case 39:
+{ yyval = not(same(val_peek(2), val_peek(0))); }
+break;
+case 35:
+//#line 279 "e.y"
+{ yyval = call(val_peek(2), "and", val_peek(0)); }
+break;
+case 36:
 //#line 280 "e.y"
-                    {
-                        yyval = matchBind(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 40:
+{ yyval = call(val_peek(2), "or", val_peek(0)); }
+break;
+case 37:
 //#line 281 "e.y"
-                    {
-                        yyval = not(matchBind(val_peek(2), val_peek(0)));
-                    }
-                    break;
-                case 41:
-//#line 293 "e.y"
-                    {
-                        yyval = list(val_peek(0));
-                    }
-                    break;
-                case 44:
-//#line 298 "e.y"
-                    {
-                        yyval = lessThan(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 45:
-//#line 299 "e.y"
-                    {
-                        yyval = leq(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 46:
-//#line 300 "e.y"
-                    {
-                        yyval = asBigAs(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 47:
-//#line 301 "e.y"
-                    {
-                        yyval = geq(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 48:
+{ yyval = call(val_peek(2), "xor", val_peek(0)); }
+break;
+case 38:
+//#line 282 "e.y"
+{ yyval = call(val_peek(2), "butNot", val_peek(0)); }
+break;
+case 39:
+//#line 284 "e.y"
+{ yyval = matchBind(val_peek(2), val_peek(0)); }
+break;
+case 40:
+//#line 285 "e.y"
+{ yyval = not(matchBind(val_peek(2), val_peek(0))); }
+break;
+case 41:
+//#line 297 "e.y"
+{ yyval = list(val_peek(0)); }
+break;
+case 44:
 //#line 302 "e.y"
-                    {
-                        yyval = greaterThan(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 50:
-//#line 311 "e.y"
-                    {
-                        yyval = thru(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 51:
-//#line 312 "e.y"
-                    {
-                        yyval = till(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 53:
-//#line 321 "e.y"
-                    {
-                        yyval = call(val_peek(2), "shiftLeft", val_peek(0));
-                    }
-                    break;
-                case 54:
-//#line 322 "e.y"
-                    {
-                        yyval = call(val_peek(2), "shiftLeft",
-                                     list(call(val_peek(0), "negate", list())));
-                    }
-                    break;
-                case 55:
-//#line 332 "e.y"
-                    {
-                        yyval = list(val_peek(0));
-                    }
-                    break;
-                case 58:
-//#line 337 "e.y"
-                    {
-                        yyval = call(val_peek(2), "add", val_peek(0));
-                    }
-                    break;
-                case 59:
-//#line 338 "e.y"
-                    {
-                        yyval = call(val_peek(2), "subtract", val_peek(0));
-                    }
-                    break;
-                case 60:
-//#line 346 "e.y"
-                    {
-                        yyval = list(val_peek(0));
-                    }
-                    break;
-                case 63:
-//#line 351 "e.y"
-                    {
-                        yyval = call(val_peek(2), "multiply", val_peek(0));
-                    }
-                    break;
-                case 64:
-//#line 352 "e.y"
-                    {
-                        yyval = call(val_peek(2), "approxDivide", val_peek(0));
-                    }
-                    break;
-                case 65:
-//#line 353 "e.y"
-                    {
-                        yyval = call(val_peek(2), "floorDivide", val_peek(0));
-                    }
-                    break;
-                case 66:
-//#line 354 "e.y"
-                    {
-                        yyval = call(val_peek(2), "remainder", val_peek(0));
-                    }
-                    break;
-                case 67:
+{ yyval = lessThan(val_peek(2), val_peek(0)); }
+break;
+case 45:
+//#line 303 "e.y"
+{ yyval = leq(val_peek(2), val_peek(0)); }
+break;
+case 46:
+//#line 304 "e.y"
+{ yyval = asBigAs(val_peek(2), val_peek(0)); }
+break;
+case 47:
+//#line 305 "e.y"
+{ yyval = geq(val_peek(2), val_peek(0)); }
+break;
+case 48:
+//#line 306 "e.y"
+{ yyval = greaterThan(val_peek(2), val_peek(0)); }
+break;
+case 50:
+//#line 315 "e.y"
+{ yyval = thru(val_peek(2), val_peek(0)); }
+break;
+case 51:
+//#line 316 "e.y"
+{ yyval = till(val_peek(2), val_peek(0)); }
+break;
+case 53:
+//#line 325 "e.y"
+{ yyval = call(val_peek(2), "shiftLeft", val_peek(0)); }
+break;
+case 54:
+//#line 326 "e.y"
+{ yyval = call(val_peek(2), "shiftLeft",
+                                            list(call(val_peek(0), "negate", list())));
+                                }
+break;
+case 55:
+//#line 336 "e.y"
+{ yyval = list(val_peek(0)); }
+break;
+case 58:
+//#line 341 "e.y"
+{ yyval = call(val_peek(2), "add", val_peek(0)); }
+break;
+case 59:
+//#line 342 "e.y"
+{ yyval = call(val_peek(2), "subtract", val_peek(0)); }
+break;
+case 60:
+//#line 350 "e.y"
+{ yyval = list(val_peek(0)); }
+break;
+case 63:
 //#line 355 "e.y"
-                    {
-                        yyval = mod(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 68:
-//#line 363 "e.y"
-                    {
-                        yyval = list(val_peek(0));
-                    }
-                    break;
-                case 71:
-//#line 368 "e.y"
-                    {
-                        yyval = call(val_peek(2), "pow", val_peek(0));
-                    }
-                    break;
-                case 72:
-//#line 377 "e.y"
-                    {
-                        yyval = list(val_peek(0));
-                    }
-                    break;
-                case 75:
-//#line 382 "e.y"
-                    {
-                        yyval = call(val_peek(0), "not", list());
-                    }
-                    break;
-                case 76:
-//#line 383 "e.y"
-                    {
-                        yyval = call(val_peek(0), "complement", list());
-                    }
-                    break;
-                case 77:
-//#line 384 "e.y"
-                    {
-                        yyval = call(val_peek(0), "negate", list());
-                    }
-                    break;
-                case 78:
-//#line 385 "e.y"
-                    {
-                        yyval = slotExpr(val_peek(0));
-                    }
-                    break;
-                case 81:
-//#line 397 "e.y"
-                    {
-                        yyval = call(val_peek(3), "get", val_peek(1));
-                    }
-                    break;
-                case 82:
-//#line 398 "e.y"
-                    {
-                        yyval = send(val_peek(3), val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 83:
-//#line 399 "e.y"
-                    {
-                        yyval = send(val_peek(2), "run", val_peek(0));
-                    }
-                    break;
-                case 84:
+{ yyval = call(val_peek(2), "multiply", val_peek(0)); }
+break;
+case 64:
+//#line 356 "e.y"
+{ yyval = call(val_peek(2), "approxDivide", val_peek(0)); }
+break;
+case 65:
+//#line 357 "e.y"
+{ yyval = call(val_peek(2), "floorDivide", val_peek(0)); }
+break;
+case 66:
+//#line 358 "e.y"
+{ yyval = call(val_peek(2), "remainder", val_peek(0)); }
+break;
+case 67:
+//#line 359 "e.y"
+{ yyval = mod(val_peek(2), val_peek(0)); }
+break;
+case 68:
+//#line 367 "e.y"
+{ yyval = list(val_peek(0)); }
+break;
+case 71:
+//#line 372 "e.y"
+{ yyval = call(val_peek(2), "pow", val_peek(0)); }
+break;
+case 72:
+//#line 381 "e.y"
+{ yyval = list(val_peek(0)); }
+break;
+case 75:
+//#line 386 "e.y"
+{ yyval = call(val_peek(0), "not", list()); }
+break;
+case 76:
+//#line 387 "e.y"
+{ yyval = call(val_peek(0), "complement", list());}
+break;
+case 77:
+//#line 388 "e.y"
+{ yyval = call(val_peek(0), "negate", list()); }
+break;
+case 78:
+//#line 389 "e.y"
+{ yyval = slotExpr(val_peek(0)); }
+break;
+case 81:
 //#line 401 "e.y"
-                    {
-                        pocket("no-paren-call");
-                        yyval = send(val_peek(2), val_peek(0), list());
-                    }
-                    break;
-                case 85:
+{ yyval = call(val_peek(3), "get", val_peek(1)); }
+break;
+case 82:
+//#line 402 "e.y"
+{ yyval = send(val_peek(3), val_peek(1), val_peek(0)); }
+break;
+case 83:
 //#line 403 "e.y"
-                    {
-                        pocket("no-paren-call");
-                        yyval = call(val_peek(1), val_peek(0), list());
-                    }
-                    break;
-                case 86:
+{ yyval = send(val_peek(2), "run", val_peek(0)); }
+break;
+case 84:
 //#line 405 "e.y"
-                    {
-                        pocket("dot-props");
-                        yyval = property(val_peek(2), val_peek(0), list());
-                    }
-                    break;
-                case 87:
+{ pocket("no-paren-call");
+                                          yyval = send(val_peek(2), val_peek(0), list()); }
+break;
+case 85:
 //#line 407 "e.y"
-                    {
-                        pocket("dot-props");
-                        yyval = property(val_peek(3), val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 88:
-//#line 415 "e.y"
-                    {
-                        yyval = doMeta(val_peek(1), "run", val_peek(0));
-                    }
-                    break;
-                case 89:
-//#line 416 "e.y"
-                    {
-                        yyval = doMeta(val_peek(2), val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 90:
-//#line 417 "e.y"
-                    {
-                        yyval = doMetaSend(val_peek(2), "run", val_peek(0));
-                    }
-                    break;
-                case 91:
-//#line 418 "e.y"
-                    {
-                        yyval = doMetaSend(val_peek(3), val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 92:
+{ pocket("no-paren-call");
+                                          yyval = call(val_peek(1), val_peek(0), list()); }
+break;
+case 86:
+//#line 409 "e.y"
+{ pocket("dot-props");
+                                          yyval = property(val_peek(2), val_peek(0), list()); }
+break;
+case 87:
+//#line 411 "e.y"
+{ pocket("dot-props");
+                                          yyval = property(val_peek(3), val_peek(1), val_peek(0)); }
+break;
+case 88:
+//#line 419 "e.y"
+{ yyval = doMeta(val_peek(1), "run", val_peek(0)); }
+break;
+case 89:
 //#line 420 "e.y"
-                    {
-                        pocket("no-paren-call");
-                        yyval = doMeta(val_peek(1), val_peek(0), list());
-                    }
-                    break;
-                case 93:
+{ yyval = doMeta(val_peek(2), val_peek(1), val_peek(0)); }
+break;
+case 90:
+//#line 421 "e.y"
+{ yyval = doMetaSend(val_peek(2), "run", val_peek(0)); }
+break;
+case 91:
 //#line 422 "e.y"
-                    {
-                        pocket("no-paren-call");
-                        yyval = doMetaSend(val_peek(2), val_peek(0), list());
-                    }
-                    break;
-                case 95:
-//#line 436 "e.y"
-                    {
-                        yyval = call(val_peek(1), "run", val_peek(0));
-                    }
-                    break;
-                case 96:
-//#line 437 "e.y"
-                    {
-                        yyval = call(val_peek(2), val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 97:
-//#line 445 "e.y"
-                    {
-                        yyval = literal(val_peek(0));
-                    }
-                    break;
-                case 98:
-//#line 446 "e.y"
-                    {
-                        yyval = literal(val_peek(0));
-                    }
-                    break;
-                case 99:
-//#line 447 "e.y"
-                    {
-                        yyval = literal(val_peek(0));
-                    }
-                    break;
-                case 100:
-//#line 448 "e.y"
-                    {
-                        yyval = literal(val_peek(0));
-                    }
-                    break;
-                case 101:
+{ yyval = doMetaSend(val_peek(3), val_peek(1), val_peek(0)); }
+break;
+case 92:
+//#line 424 "e.y"
+{ pocket("no-paren-call");
+                                          yyval = doMeta(val_peek(1), val_peek(0), list()); }
+break;
+case 93:
+//#line 426 "e.y"
+{ pocket("no-paren-call");
+                                          yyval = doMetaSend(val_peek(2), val_peek(0), list()); }
+break;
+case 95:
+//#line 440 "e.y"
+{ yyval = call(val_peek(1), "run", val_peek(0)); }
+break;
+case 96:
+//#line 441 "e.y"
+{ yyval = call(val_peek(2), val_peek(1), val_peek(0)); }
+break;
+case 97:
 //#line 449 "e.y"
-                    {
-                        yyval = literal(val_peek(0));
-                    }
-                    break;
-                case 103:
+{ yyval = literal(val_peek(0)); }
+break;
+case 98:
+//#line 450 "e.y"
+{ yyval = literal(val_peek(0)); }
+break;
+case 99:
+//#line 451 "e.y"
+{ yyval = literal(val_peek(0)); }
+break;
+case 100:
+//#line 452 "e.y"
+{ yyval = literal(val_peek(0)); }
+break;
+case 101:
 //#line 453 "e.y"
-                    {
-                        yyval = uriExpr(val_peek(0));
-                    }
-                    break;
-                case 104:
-//#line 454 "e.y"
-                    {
-                        yyval = uriExpr(val_peek(2), val_peek(1));
-                    }
-                    break;
-                case 105:
-//#line 456 "e.y"
-                    {
-                        yyval = quasiExpr(val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 107:
-//#line 459 "e.y"
-                    {
-                        yyval = tuple(val_peek(1));
-                    }
-                    break;
-                case 108:
+{ yyval = literal(val_peek(0)); }
+break;
+case 103:
+//#line 457 "e.y"
+{ yyval = uriExpr(val_peek(0)); }
+break;
+case 104:
+//#line 458 "e.y"
+{ yyval = uriExpr(val_peek(2),val_peek(1)); }
+break;
+case 105:
 //#line 460 "e.y"
-                    {
-                        yyval = map(val_peek(1));
-                    }
-                    break;
-                case 109:
-//#line 462 "e.y"
-                    {
-                        yyval = hide(val_peek(0));
-                    }
-                    break;
-                case 110:
+{ yyval = quasiExpr(val_peek(1),val_peek(0)); }
+break;
+case 107:
+//#line 463 "e.y"
+{ yyval = tuple(val_peek(1)); }
+break;
+case 108:
 //#line 464 "e.y"
-                    {
-                        yyval = escape(val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 111:
+{ yyval = map(val_peek(1)); }
+break;
+case 109:
 //#line 466 "e.y"
-                    {
-                        yyval = whilex(val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 112:
+{ yyval = hide(val_peek(0)); }
+break;
+case 110:
 //#line 468 "e.y"
-                    {
-                        yyval = switchx(val_peek(2), val_peek(1));
-                    }
-                    break;
-                case 113:
+{ yyval = escape(val_peek(1),val_peek(0)); }
+break;
+case 111:
 //#line 470 "e.y"
-                    {
-                        yyval = tryx(val_peek(2), val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 118:
-//#line 478 "e.y"
-                    {
-                        yyval = quasiLiteralExpr(val_peek(1));
-                    }
-                    break;
-                case 119:
-//#line 479 "e.y"
-                    {
-                        yyval = quasiLiteralExpr(val_peek(0));
-                    }
-                    break;
-                case 120:
-//#line 480 "e.y"
-                    {
-                        yyval = quasiLiteralExpr();
-                    }
-                    break;
-                case 121:
-//#line 481 "e.y"
-                    {
-                        yyval = quasiPatternExpr(val_peek(1));
-                    }
-                    break;
-                case 122:
+{ yyval = whilex(val_peek(1),val_peek(0)); }
+break;
+case 112:
+//#line 472 "e.y"
+{ yyval = switchx(val_peek(2),val_peek(1)); }
+break;
+case 113:
+//#line 474 "e.y"
+{ yyval = tryx(val_peek(2),val_peek(1),val_peek(0)); }
+break;
+case 118:
 //#line 482 "e.y"
-                    {
-                        yyval = quasiPatternExpr(val_peek(0));
-                    }
-                    break;
-                case 123:
+{ yyval = quasiLiteralExpr(val_peek(1)); }
+break;
+case 119:
+//#line 483 "e.y"
+{ yyval = quasiLiteralExpr(val_peek(0)); }
+break;
+case 120:
+//#line 484 "e.y"
+{ yyval = quasiLiteralExpr(); }
+break;
+case 121:
 //#line 485 "e.y"
-                    {
-                        reserved("select");
-                    }
-                    break;
-                case 124:
+{ yyval = quasiPatternExpr(val_peek(1)); }
+break;
+case 122:
 //#line 486 "e.y"
-                    {
-                        pocket("typedef");
-                        yyval = val_peek(0);
-                    }
-                    break;
-                case 126:
-//#line 495 "e.y"
-                    {
-                        yyval = object(val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 127:
-//#line 496 "e.y"
-                    {
-                        yyval = methObject(val_peek(3), val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 128:
-//#line 497 "e.y"
-                    {
-                        yyval = thunk(val_peek(0));
-                    }
-                    break;
-                case 129:
+{ yyval = quasiPatternExpr(val_peek(0)); }
+break;
+case 123:
+//#line 489 "e.y"
+{ reserved("select"); }
+break;
+case 124:
+//#line 490 "e.y"
+{ pocket("typedef");
+                                                  yyval = val_peek(0); }
+break;
+case 126:
 //#line 499 "e.y"
-                    {
-                        yyval = classExpr(val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 130:
+{ yyval = object(val_peek(1), val_peek(0)); }
+break;
+case 127:
+//#line 500 "e.y"
+{ yyval = methObject(val_peek(3),val_peek(1),val_peek(0)); }
+break;
+case 128:
 //#line 501 "e.y"
-                    {
-                        pocket("anon-lambda");
-                        yyval = methObject(audits(ignore(),
-                                                  list()),
-                                           val_peek(1),
-                                           val_peek(0));
-                    }
-                    break;
-                case 131:
-//#line 506 "e.y"
-                    {
-                        pocket("anon-lambda");
-                        yyval = thunk(val_peek(0));
-                    }
-                    break;
-                case 132:
-//#line 514 "e.y"
-                    {
-                        yyval = noun(val_peek(0));
-                    }
-                    break;
-                case 133:
-//#line 523 "e.y"
-                    {
-                        yyval = val_peek(1);
-                    }
-                    break;
-                case 134:
-//#line 532 "e.y"
-                    {
-                        yyval = ifx(val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 135:
-//#line 533 "e.y"
-                    {
-                        yyval = ifx(val_peek(3), val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 136:
-//#line 534 "e.y"
-                    {
-                        yyval = ifx(val_peek(4), val_peek(3), val_peek(0));
-                    }
-                    break;
-                case 137:
-//#line 542 "e.y"
-                    {
-                        yyval = forx(val_peek(5), val_peek(3), val_peek(1));
-                    }
-                    break;
-                case 138:
-//#line 550 "e.y"
-                    {
-                        yyval = when(val_peek(3), val_peek(2), val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 139:
-//#line 560 "e.y"
-                    {
-                        yyval = macro(val_peek(4), val_peek(2), val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 140:
-//#line 562 "e.y"
-                    {
-                        yyval = macro(val_peek(5), val_peek(3), val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 141:
+{ yyval = thunk(val_peek(0)); }
+break;
+case 129:
+//#line 503 "e.y"
+{ yyval = classExpr(val_peek(1),val_peek(0)); }
+break;
+case 130:
+//#line 505 "e.y"
+{ pocket("anon-lambda");
+                                          yyval = methObject(audits(ignore(),
+                                                                 list()),
+                                                          val_peek(1),
+                                                          val_peek(0)); }
+break;
+case 131:
+//#line 510 "e.y"
+{ pocket("anon-lambda");
+                                          yyval = thunk(val_peek(0)); }
+break;
+case 132:
+//#line 518 "e.y"
+{ yyval = noun(val_peek(0)); }
+break;
+case 133:
+//#line 527 "e.y"
+{ yyval = val_peek(1); }
+break;
+case 134:
+//#line 536 "e.y"
+{ yyval = ifx(val_peek(1), val_peek(0)); }
+break;
+case 135:
+//#line 537 "e.y"
+{ yyval = ifx(val_peek(3), val_peek(2), val_peek(0)); }
+break;
+case 136:
+//#line 538 "e.y"
+{ yyval = ifx(val_peek(4), val_peek(3), val_peek(0)); }
+break;
+case 137:
+//#line 546 "e.y"
+{ yyval = forx(val_peek(5),val_peek(3),val_peek(1)); }
+break;
+case 138:
+//#line 554 "e.y"
+{ yyval = when(val_peek(3),val_peek(2),val_peek(1),val_peek(0)); }
+break;
+case 139:
+//#line 564 "e.y"
+{ yyval = macro(val_peek(4), val_peek(2), val_peek(1), val_peek(0)); }
+break;
+case 140:
 //#line 566 "e.y"
-                    {
-                        yyval = null;
-                    }
-                    break;
-                case 142:
-//#line 568 "e.y"
-                    {
-                        yyval = macro(val_peek(5), val_peek(3), val_peek(2), val_peek(1));
-                    }
-                    break;
-                case 143:
+{ yyval = macro(val_peek(5), val_peek(3), val_peek(2), val_peek(0)); }
+break;
+case 141:
 //#line 570 "e.y"
-                    {
-                        yyval = macro(val_peek(5), val_peek(3), val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 144:
-//#line 578 "e.y"
-                    {
-                        yyval = null;
-                    }
-                    break;
-                case 147:
-//#line 585 "e.y"
-                    {
-                        yyval = noun("simple__quasiParser");
-                    }
-                    break;
-                case 148:
-//#line 586 "e.y"
-                    {
-                        yyval = noun(val_peek(0) + "__quasiParser");
-                    }
-                    break;
-                case 149:
-//#line 587 "e.y"
-                    {
-                        yyval = val_peek(1);
-                    }
-                    break;
-                case 150:
+{ yyval = null; }
+break;
+case 142:
+//#line 572 "e.y"
+{ yyval = macro(val_peek(5), val_peek(3), val_peek(2), val_peek(1)); }
+break;
+case 143:
+//#line 574 "e.y"
+{ yyval = macro(val_peek(5), val_peek(3), val_peek(2), val_peek(0)); }
+break;
+case 144:
+//#line 582 "e.y"
+{ yyval = null; }
+break;
+case 147:
+//#line 589 "e.y"
+{ yyval = noun("simple__quasiParser"); }
+break;
+case 148:
+//#line 590 "e.y"
+{ yyval = noun(val_peek(0) +  "__quasiParser"); }
+break;
+case 149:
 //#line 591 "e.y"
-                    {
-                        yyval = list(val_peek(0));
-                    }
-                    break;
-                case 151:
-//#line 592 "e.y"
-                    {
-                        yyval = with(val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 152:
+{ yyval = val_peek(1); }
+break;
+case 150:
+//#line 595 "e.y"
+{ yyval = list(val_peek(0)); }
+break;
+case 151:
 //#line 596 "e.y"
-                    {
-                        yyval = list(val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 153:
-//#line 597 "e.y"
-                    {
-                        yyval = with(with(val_peek(2), val_peek(1)), val_peek(0));
-                    }
-                    break;
-                case 154:
+{ yyval = with(val_peek(1), val_peek(0)); }
+break;
+case 152:
+//#line 600 "e.y"
+{ yyval = list(val_peek(1), val_peek(0)); }
+break;
+case 153:
 //#line 601 "e.y"
-                    {
-                        yyval = dollarNoun(val_peek(0));
-                    }
-                    break;
-                case 155:
-//#line 602 "e.y"
-                    {
-                        yyval = val_peek(1);
-                    }
-                    break;
-                case 158:
-//#line 620 "e.y"
-                    {
-                        yyval = list(val_peek(0));
-                    }
-                    break;
-                case 159:
-//#line 621 "e.y"
-                    {
-                        yyval = with(val_peek(3), val_peek(0));
-                    }
-                    break;
-                case 161:
-//#line 631 "e.y"
-                    {
-                        yyval = list(val_peek(0));
-                    }
-                    break;
-                case 162:
-//#line 632 "e.y"
-                    {
-                        yyval = with(val_peek(3), val_peek(0));
-                    }
-                    break;
-                case 163:
-//#line 639 "e.y"
-                    {
-                        yyval = new Assoc(ignore(), val_peek(0));
-                    }
-                    break;
-                case 165:
-//#line 644 "e.y"
-                    {
-                        yyval = new Assoc(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 166:
-//#line 645 "e.y"
-                    {
-                        reserved("var-extract-pattern");
-                    }
-                    break;
-                case 168:
-//#line 650 "e.y"
-                    {
-                        yyval = suchThat(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 169:
-//#line 652 "e.y"
-                    {
-                        reserved("meta pattern");
-                    }
-                    break;
-                case 171:
-//#line 657 "e.y"
-                    {
-                        yyval = listPattern(val_peek(1));
-                    }
-                    break;
-                case 172:
-//#line 658 "e.y"
-                    {
-                        yyval = cdrPattern(val_peek(3), val_peek(0));
-                    }
-                    break;
-                case 173:
-//#line 660 "e.y"
-                    {
-                        reserved("map pattern");
-                    }
-                    break;
-                case 174:
+{ yyval = with(with(val_peek(2), val_peek(1)), val_peek(0)); }
+break;
+case 154:
+//#line 605 "e.y"
+{ yyval = dollarNoun(val_peek(0)); }
+break;
+case 155:
+//#line 606 "e.y"
+{ yyval = val_peek(1); }
+break;
+case 158:
+//#line 624 "e.y"
+{ yyval = list(val_peek(0)); }
+break;
+case 159:
+//#line 625 "e.y"
+{ yyval = with(val_peek(3), val_peek(0)); }
+break;
+case 161:
+//#line 635 "e.y"
+{ yyval = list(val_peek(0)); }
+break;
+case 162:
+//#line 636 "e.y"
+{ yyval = with(val_peek(3), val_peek(0)); }
+break;
+case 163:
+//#line 643 "e.y"
+{ yyval = new Assoc(ignore(), val_peek(0)); }
+break;
+case 165:
+//#line 648 "e.y"
+{ yyval = new Assoc(val_peek(2), val_peek(0)); }
+break;
+case 166:
+//#line 649 "e.y"
+{ reserved("var-extract-pattern"); }
+break;
+case 168:
+//#line 654 "e.y"
+{ yyval = suchThat(val_peek(2), val_peek(0)); }
+break;
+case 169:
+//#line 656 "e.y"
+{ reserved("meta pattern"); }
+break;
+case 171:
 //#line 661 "e.y"
-                    {
-                        reserved("map pattern");
-                    }
-                    break;
-                case 176:
-//#line 666 "e.y"
-                    {
-                        yyval = patternEquals(val_peek(0));
-                    }
-                    break;
-                case 178:
-//#line 671 "e.y"
-                    {
-                        yyval = quasiPattern(val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 179:
+{ yyval = listPattern(val_peek(1)); }
+break;
+case 172:
+//#line 662 "e.y"
+{ yyval = cdrPattern(val_peek(3), val_peek(0)); }
+break;
+case 173:
+//#line 664 "e.y"
+{ reserved("map pattern"); }
+break;
+case 174:
+//#line 665 "e.y"
+{ reserved("map pattern"); }
+break;
+case 176:
+//#line 670 "e.y"
+{ yyval = patternEquals(val_peek(0)); }
+break;
+case 178:
 //#line 675 "e.y"
-                    {
-                        yyval = list(val_peek(0));
-                    }
-                    break;
-                case 180:
-//#line 676 "e.y"
-                    {
-                        yyval = with(val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 181:
+{ yyval = quasiPattern(val_peek(1), val_peek(0)); }
+break;
+case 179:
+//#line 679 "e.y"
+{ yyval = list(val_peek(0)); }
+break;
+case 180:
 //#line 680 "e.y"
-                    {
-                        yyval = list(val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 182:
-//#line 681 "e.y"
-                    {
-                        yyval = with(with(val_peek(2), val_peek(1)), val_peek(0));
-                    }
-                    break;
-                case 185:
-//#line 690 "e.y"
-                    {
-                        yyval = atNoun(val_peek(0));
-                    }
-                    break;
-                case 186:
-//#line 691 "e.y"
-                    {
-                        yyval = val_peek(1);
-                    }
-                    break;
-                case 187:
-//#line 704 "e.y"
-                    {
-                        yyval = finalPattern(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 188:
-//#line 705 "e.y"
-                    {
-                        yyval = finalPattern(val_peek(0));
-                    }
-                    break;
-                case 189:
-//#line 706 "e.y"
-                    {
-                        yyval = slotDefiner(val_peek(0));
-                    }
-                    break;
-                case 190:
-//#line 707 "e.y"
-                    {
-                        yyval = ignore();
-                    }
-                    break;
-                case 191:
+{ yyval = with(val_peek(1), val_peek(0)); }
+break;
+case 181:
+//#line 684 "e.y"
+{ yyval = list(val_peek(1), val_peek(0)); }
+break;
+case 182:
+//#line 685 "e.y"
+{ yyval = with(with(val_peek(2), val_peek(1)), val_peek(0));}
+break;
+case 185:
+//#line 694 "e.y"
+{ yyval = atNoun(val_peek(0)); }
+break;
+case 186:
+//#line 695 "e.y"
+{ yyval = val_peek(1); }
+break;
+case 187:
 //#line 708 "e.y"
-                    {
-                        reserved("anon guard");
-                    }
-                    break;
-                case 194:
+{ yyval = finalPattern(val_peek(2), val_peek(0)); }
+break;
+case 188:
+//#line 709 "e.y"
+{ yyval = finalPattern(val_peek(0)); }
+break;
+case 189:
+//#line 710 "e.y"
+{ yyval = slotDefiner(val_peek(0)); }
+break;
+case 190:
+//#line 711 "e.y"
+{ yyval = ignore(); }
+break;
+case 191:
 //#line 712 "e.y"
-                    {
-                        yyval = quasiLiteralPatt(val_peek(1));
-                    }
-                    break;
-                case 195:
-//#line 713 "e.y"
-                    {
-                        yyval = quasiPatternPatt(val_peek(1));
-                    }
-                    break;
-                case 196:
+{ reserved("anon guard"); }
+break;
+case 194:
+//#line 716 "e.y"
+{ yyval = quasiLiteralPatt(val_peek(1)); }
+break;
+case 195:
 //#line 717 "e.y"
-                    {
-                        yyval = bindDefiner(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 197:
-//#line 718 "e.y"
-                    {
-                        yyval = bindDefiner(val_peek(0));
-                    }
-                    break;
-                case 198:
+{ yyval = quasiPatternPatt(val_peek(1)); }
+break;
+case 196:
+//#line 721 "e.y"
+{ yyval = bindDefiner(val_peek(2), val_peek(0)); }
+break;
+case 197:
 //#line 722 "e.y"
-                    {
-                        yyval = varPattern(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 199:
-//#line 723 "e.y"
-                    {
-                        yyval = varPattern(val_peek(0));
-                    }
-                    break;
-                case 200:
-//#line 732 "e.y"
-                    {
-                        yyval = finalPattern(val_peek(0));
-                    }
-                    break;
-                case 201:
-//#line 733 "e.y"
-                    {
-                        yyval = ignore();
-                    }
-                    break;
-                case 202:
-//#line 734 "e.y"
-                    {
-                        yyval = bindDefiner(val_peek(0));
-                    }
-                    break;
-                case 203:
-//#line 735 "e.y"
-                    {
-                        yyval = varPattern(val_peek(0));
-                    }
-                    break;
-                case 204:
+{ yyval = bindDefiner(val_peek(0)); }
+break;
+case 198:
+//#line 726 "e.y"
+{ yyval = varPattern(val_peek(2), val_peek(0)); }
+break;
+case 199:
+//#line 727 "e.y"
+{ yyval = varPattern(val_peek(0)); }
+break;
+case 200:
 //#line 736 "e.y"
-                    {
-                        yyval = quasiLiteralPatt(val_peek(1));
-                    }
-                    break;
-                case 205:
+{ yyval = finalPattern(val_peek(0)); }
+break;
+case 201:
 //#line 737 "e.y"
-                    {
-                        yyval = quasiPatternPatt(val_peek(1));
-                    }
-                    break;
-                case 207:
-//#line 754 "e.y"
-                    {
-                        yyval = val_peek(0);
-                    }
-                    break;
-                case 208:
-//#line 755 "e.y"
-                    {
-                        yyval = bindDefiner(val_peek(0));
-                    }
-                    break;
-                case 209:
-//#line 756 "e.y"
-                    {
-                        yyval = varPattern(val_peek(0));
-                    }
-                    break;
-                case 210:
-//#line 763 "e.y"
-                    {
-                        yyval = audits(val_peek(0), list());
-                    }
-                    break;
-                case 211:
-//#line 764 "e.y"
-                    {
-                        pocket("auditors");
-                        yyval = audits(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 212:
-//#line 772 "e.y"
-                    {
-                        yyval = audits(val_peek(0), list());
-                    }
-                    break;
-                case 213:
-//#line 773 "e.y"
-                    {
-                        pocket("auditors");
-                        yyval = audits(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 214:
-//#line 778 "e.y"
-                    {
-                        yyval = list(val_peek(0));
-                    }
-                    break;
-                case 215:
-//#line 779 "e.y"
-                    {
-                        yyval = with(val_peek(3), val_peek(0));
-                    }
-                    break;
-                case 216:
-//#line 791 "e.y"
-                    {
-                        yyval = list();
-                    }
-                    break;
-                case 217:
-//#line 792 "e.y"
-                    {
-                        yyval = append(list(val_peek(3)), val_peek(1));
-                    }
-                    break;
-                case 220:
-//#line 806 "e.y"
-                    {
-                        yyval = method(val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 221:
-//#line 808 "e.y"
-                    {
-                        reserved("fields");
-                    }
-                    break;
-                case 222:
-//#line 809 "e.y"
-                    {
-                        reserved("on event");
-                    }
-                    break;
-                case 223:
+{ yyval = ignore(); }
+break;
+case 202:
+//#line 738 "e.y"
+{ yyval = bindDefiner(val_peek(0)); }
+break;
+case 203:
+//#line 739 "e.y"
+{ yyval = varPattern(val_peek(0)); }
+break;
+case 204:
+//#line 740 "e.y"
+{ yyval = quasiLiteralPatt(val_peek(1)); }
+break;
+case 205:
+//#line 741 "e.y"
+{ yyval = quasiPatternPatt(val_peek(1)); }
+break;
+case 207:
+//#line 758 "e.y"
+{ yyval = val_peek(0); }
+break;
+case 208:
+//#line 759 "e.y"
+{ yyval = bindDefiner(val_peek(0)); }
+break;
+case 209:
+//#line 760 "e.y"
+{ yyval = varPattern(val_peek(0)); }
+break;
+case 210:
+//#line 767 "e.y"
+{ yyval = audits(val_peek(0), list()); }
+break;
+case 211:
+//#line 768 "e.y"
+{ pocket("auditors");
+                                                  yyval = audits(val_peek(2), val_peek(0)); }
+break;
+case 212:
+//#line 776 "e.y"
+{ yyval = audits(val_peek(0), list()); }
+break;
+case 213:
+//#line 777 "e.y"
+{ pocket("auditors");
+                                                  yyval = audits(val_peek(2), val_peek(0)); }
+break;
+case 214:
+//#line 782 "e.y"
+{ yyval = list(val_peek(0)); }
+break;
+case 215:
+//#line 783 "e.y"
+{ yyval = with(val_peek(3), val_peek(0)); }
+break;
+case 216:
+//#line 795 "e.y"
+{ yyval = list(); }
+break;
+case 217:
+//#line 796 "e.y"
+{ yyval = append(list(val_peek(3)),val_peek(1)); }
+break;
+case 220:
 //#line 810 "e.y"
-                    {
-                        reserved("sealed meta");
-                    }
-                    break;
-                case 224:
-//#line 811 "e.y"
-                    {
-                        reserved("sealed meta");
-                    }
-                    break;
-                case 225:
-//#line 819 "e.y"
-                    {
-                        yyval = methHead("run", val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 226:
-//#line 820 "e.y"
-                    {
-                        yyval = methHead(val_peek(4), val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 227:
-//#line 822 "e.y"
-                    {
-                        pocket("no-paren-method");
-                        yyval = methHead(val_peek(1), list(), val_peek(0));
-                    }
-                    break;
-                case 228:
-//#line 831 "e.y"
-                    {
-                        yyval = methHead("run", val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 229:
-//#line 833 "e.y"
-                    {
-                        pocket("one-method-object");
-                        yyval = methHead(val_peek(4), val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 230:
+{ yyval = method(val_peek(1), val_peek(0)); }
+break;
+case 221:
+//#line 812 "e.y"
+{ reserved("fields"); }
+break;
+case 222:
+//#line 813 "e.y"
+{ reserved("on event"); }
+break;
+case 223:
+//#line 814 "e.y"
+{ reserved("sealed meta"); }
+break;
+case 224:
+//#line 815 "e.y"
+{ reserved("sealed meta"); }
+break;
+case 225:
+//#line 823 "e.y"
+{ yyval = methHead("run", val_peek(2), val_peek(0)); }
+break;
+case 226:
+//#line 824 "e.y"
+{ yyval = methHead(val_peek(4), val_peek(2), val_peek(0)); }
+break;
+case 227:
+//#line 826 "e.y"
+{ pocket("no-paren-method");
+                                               yyval = methHead(val_peek(1), list(), val_peek(0)); }
+break;
+case 228:
 //#line 835 "e.y"
-                    {
-                        pocket("no-paren-method");
-                        yyval = methHead(val_peek(1), list(), val_peek(0));
-                    }
-                    break;
-                case 231:
-//#line 844 "e.y"
-                    {
-                        yyval = list(val_peek(5), val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 232:
-//#line 854 "e.y"
-                    {
-                        yyval = matcher(val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 233:
-//#line 863 "e.y"
-                    {
-                        yyval = delegatex(val_peek(0));
-                    }
-                    break;
-                case 234:
-//#line 870 "e.y"
-                    {
-                        yyval = VOID;
-                    }
-                    break;
-                case 235:
-//#line 871 "e.y"
-                    {
-                        yyval = val_peek(0);
-                    }
-                    break;
-                case 236:
+{ yyval = methHead("run", val_peek(2), val_peek(0)); }
+break;
+case 229:
+//#line 837 "e.y"
+{ pocket("one-method-object");
+                                               yyval = methHead(val_peek(4), val_peek(2), val_peek(0)); }
+break;
+case 230:
+//#line 839 "e.y"
+{ pocket("no-paren-method");
+                                               yyval = methHead(val_peek(1), list(), val_peek(0)); }
+break;
+case 231:
+//#line 848 "e.y"
+{ yyval = list(val_peek(5), val_peek(2), val_peek(0)); }
+break;
+case 232:
+//#line 858 "e.y"
+{ yyval = matcher(val_peek(1), val_peek(0)); }
+break;
+case 233:
+//#line 867 "e.y"
+{ yyval = delegatex(val_peek(0)); }
+break;
+case 234:
+//#line 874 "e.y"
+{ yyval = VOID; }
+break;
+case 235:
 //#line 875 "e.y"
-                    {
-                        yyval = val_peek(1);
-                    }
-                    break;
-                case 237:
-//#line 884 "e.y"
-                    {
-                        yyval = list(val_peek(7), val_peek(5), val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 238:
-//#line 887 "e.y"
-                    {
-                        pocket("when-clauses");
-                        yyval = list(val_peek(5), val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 239:
-//#line 892 "e.y"
-                    {
-                        yyval = list(val_peek(0));
-                    }
-                    break;
-                case 240:
-//#line 893 "e.y"
-                    {
-                        yyval = with(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 241:
+{ yyval = val_peek(0); }
+break;
+case 236:
+//#line 879 "e.y"
+{ yyval = val_peek(1); }
+break;
+case 237:
+//#line 888 "e.y"
+{ yyval = list(val_peek(7), val_peek(5), val_peek(2), val_peek(0)); }
+break;
+case 238:
+//#line 891 "e.y"
+{ pocket("when-clauses");
+                                                  yyval = list(val_peek(5), val_peek(2), val_peek(0)); }
+break;
+case 239:
+//#line 896 "e.y"
+{ yyval = list(val_peek(0)); }
+break;
+case 240:
 //#line 897 "e.y"
-                    {
-                        list(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 246:
-//#line 915 "e.y"
-                    {
-                        yyval = list();
-                    }
-                    break;
-                case 247:
+{ yyval = with(val_peek(2), val_peek(0)); }
+break;
+case 241:
+//#line 901 "e.y"
+{ list(val_peek(2), val_peek(0)); }
+break;
+case 246:
 //#line 919 "e.y"
-                    {
-                        yyval = list();
-                    }
-                    break;
-                case 248:
-//#line 924 "e.y"
-                    {
-                        yyval = val_peek(1);
-                    }
-                    break;
-                case 249:
-//#line 929 "e.y"
-                    {
-                        pocket("lambda-args");
-                        yyval = with(val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 252:
-//#line 939 "e.y"
-                    {
-                        yyval = list(val_peek(0));
-                    }
-                    break;
-                case 253:
-//#line 940 "e.y"
-                    {
-                        yyval = with(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 254:
-//#line 945 "e.y"
-                    {
-                        yyval = list(val_peek(0));
-                    }
-                    break;
-                case 255:
-//#line 946 "e.y"
-                    {
-                        yyval = with(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 256:
+{ yyval = list(); }
+break;
+case 247:
+//#line 923 "e.y"
+{ yyval = list(); }
+break;
+case 248:
+//#line 928 "e.y"
+{ yyval = val_peek(1); }
+break;
+case 249:
+//#line 933 "e.y"
+{ pocket("lambda-args");
+                                          yyval = with(val_peek(1), val_peek(0)); }
+break;
+case 252:
+//#line 943 "e.y"
+{ yyval = list(val_peek(0)); }
+break;
+case 253:
+//#line 944 "e.y"
+{ yyval = with(val_peek(2), val_peek(0)); }
+break;
+case 254:
+//#line 949 "e.y"
+{ yyval = list(val_peek(0)); }
+break;
+case 255:
 //#line 950 "e.y"
-                    {
-                        yyval = new Assoc(val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 257:
-//#line 951 "e.y"
-                    {
-                        reserved("export binding");
-                    }
-                    break;
-                case 259:
-//#line 966 "e.y"
-                    {
-                        yyval = hilbert(val_peek(0));
-                    }
-                    break;
-                case 260:
-//#line 973 "e.y"
-                    {
-                        yyval = ((AstroToken)val_peek(0)).getData();
-                    }
-                    break;
-                case 261:
-//#line 974 "e.y"
-                    {
-                        reserved("keyword \"" +
-                                 ((AstroToken)val_peek(0)).getText() +
-                                 "\"");
-                    }
-                    break;
-                case 262:
-//#line 990 "e.y"
-                    {
-                        yyval = "add";
-                    }
-                    break;
-                case 263:
-//#line 991 "e.y"
-                    {
-                        yyval = "and";
-                    }
-                    break;
-                case 264:
-//#line 992 "e.y"
-                    {
-                        yyval = "approxDivide";
-                    }
-                    break;
-                case 265:
-//#line 993 "e.y"
-                    {
-                        yyval = "floorDivide";
-                    }
-                    break;
-                case 266:
+{ yyval = with(val_peek(2), val_peek(0)); }
+break;
+case 256:
+//#line 954 "e.y"
+{ yyval = new Assoc(val_peek(2), val_peek(0)); }
+break;
+case 257:
+//#line 955 "e.y"
+{ reserved("export binding"); }
+break;
+case 259:
+//#line 970 "e.y"
+{ yyval = hilbert(val_peek(0)); }
+break;
+case 260:
+//#line 977 "e.y"
+{ yyval = ((AstroToken)val_peek(0)).getData(); }
+break;
+case 261:
+//#line 978 "e.y"
+{ reserved("keyword \"" +
+                                           ((AstroToken)val_peek(0)).getText() +
+                                           "\""); }
+break;
+case 262:
 //#line 994 "e.y"
-                    {
-                        yyval = "shiftLeft";
-                    }
-                    break;
-                case 267:
+{ yyval = "add"; }
+break;
+case 263:
 //#line 995 "e.y"
-                    {
-                        yyval = "remainder";
-                    }
-                    break;
-                case 268:
+{ yyval = "and"; }
+break;
+case 264:
 //#line 996 "e.y"
-                    {
-                        yyval = "mod";
-                    }
-                    break;
-                case 269:
+{ yyval = "approxDivide"; }
+break;
+case 265:
 //#line 997 "e.y"
-                    {
-                        yyval = "multiply";
-                    }
-                    break;
-                case 270:
+{ yyval = "floorDivide"; }
+break;
+case 266:
 //#line 998 "e.y"
-                    {
-                        yyval = "or";
-                    }
-                    break;
-                case 271:
+{ yyval = "shiftLeft"; }
+break;
+case 267:
 //#line 999 "e.y"
-                    {
-                        yyval = "pow";
-                    }
-                    break;
-                case 272:
+{ yyval = "remainder"; }
+break;
+case 268:
 //#line 1000 "e.y"
-                    {
-                        yyval = "subtract";
-                    }
-                    break;
-                case 273:
+{ yyval = "mod"; }
+break;
+case 269:
 //#line 1001 "e.y"
-                    {
-                        yyval = "xor";
-                    }
-                    break;
-                case 274:
-//#line 1010 "e.y"
-                    {
-                        yyval = NULL;
-                    }
-                    break;
-                case 275:
-//#line 1011 "e.y"
-                    {
-                        yyval = val_peek(3);
-                    }
-                    break;
-                case 276:
+{ yyval = "multiply"; }
+break;
+case 270:
+//#line 1002 "e.y"
+{ yyval = "or"; }
+break;
+case 271:
+//#line 1003 "e.y"
+{ yyval = "pow"; }
+break;
+case 272:
+//#line 1004 "e.y"
+{ yyval = "subtract"; }
+break;
+case 273:
+//#line 1005 "e.y"
+{ yyval = "xor"; }
+break;
+case 274:
+//#line 1014 "e.y"
+{ yyval = NULL; }
+break;
+case 275:
 //#line 1015 "e.y"
-                    {
-                        yyval = val_peek(1);
-                    }
-                    break;
-                case 277:
-//#line 1020 "e.y"
-                    {
-                        yyval = eScript(val_peek(2), optMatcher(val_peek(1)));
-                    }
-                    break;
-                case 278:
-//#line 1022 "e.y"
-                    {
-                        pocket("plumbing");
-                        yyval = eScript(null, val_peek(0));
-                    }
-                    break;
-                case 279:
+{ yyval = val_peek(3); }
+break;
+case 276:
+//#line 1019 "e.y"
+{ yyval = val_peek(1); }
+break;
+case 277:
 //#line 1024 "e.y"
-                    {
-                        pocket("plumbing");
-                        yyval = eScript(null, val_peek(0));
-                    }
-                    break;
-                case 281:
-//#line 1034 "e.y"
-                    {
-                        yyval = with(val_peek(2), val_peek(1));
-                    }
-                    break;
-                case 283:
-//#line 1039 "e.y"
-                    {
-                        yyval = with(val_peek(2), val_peek(1));
-                    }
-                    break;
-                case 285:
-//#line 1044 "e.y"
-                    {
-                        yyval = with(val_peek(2), val_peek(1));
-                    }
-                    break;
-                case 288:
-//#line 1061 "e.y"
-                    {
-                        yyval = with(val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 289:
+{ yyval = eScript(val_peek(2), optMatcher(val_peek(1))); }
+break;
+case 278:
+//#line 1026 "e.y"
+{ pocket("plumbing");
+                                  yyval = eScript(null, val_peek(0)); }
+break;
+case 279:
+//#line 1028 "e.y"
+{ pocket("plumbing");
+                                  yyval = eScript(null, val_peek(0)); }
+break;
+case 281:
+//#line 1038 "e.y"
+{ yyval = with(val_peek(2), val_peek(1)); }
+break;
+case 283:
+//#line 1043 "e.y"
+{ yyval = with(val_peek(2), val_peek(1)); }
+break;
+case 285:
+//#line 1048 "e.y"
+{ yyval = with(val_peek(2), val_peek(1)); }
+break;
+case 288:
 //#line 1065 "e.y"
-                    {
-                        yyval = matcher(val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 290:
-//#line 1072 "e.y"
-                    {
-                        yyval = null;
-                    }
-                    break;
-                case 291:
-//#line 1073 "e.y"
-                    {
-                        yyval = val_peek(0);
-                    }
-                    break;
-                case 292:
-//#line 1084 "e.y"
-                    {
-                        yyval = oType(val_peek(4), val_peek(1));
-                    }
-                    break;
-                case 293:
-//#line 1085 "e.y"
-                    {
-                        yyval = oType(val_peek(2), list(val_peek(1)));
-                    }
-                    break;
-                case 297:
-//#line 1092 "e.y"
-                    {
-                        yyval = with(val_peek(3), val_peek(1));
-                    }
-                    break;
-                case 298:
+{ yyval = with(val_peek(1), val_peek(0)); }
+break;
+case 289:
+//#line 1069 "e.y"
+{ yyval = matcher(val_peek(1), val_peek(0)); }
+break;
+case 290:
+//#line 1076 "e.y"
+{ yyval = null; }
+break;
+case 291:
+//#line 1077 "e.y"
+{ yyval = val_peek(0); }
+break;
+case 292:
+//#line 1088 "e.y"
+{ yyval = oType(val_peek(4), val_peek(1)); }
+break;
+case 293:
+//#line 1089 "e.y"
+{ yyval = oType(val_peek(2), list(val_peek(1))); }
+break;
+case 297:
 //#line 1096 "e.y"
-                    {
-                        yyval = list(val_peek(0));
-                    }
-                    break;
-                case 299:
-//#line 1097 "e.y"
-                    {
-                        yyval = with(val_peek(3), val_peek(0));
-                    }
-                    break;
-                case 300:
-//#line 1099 "e.y"
-                    {
-                        reserved("on event");
-                    }
-                    break;
-                case 301:
+{ yyval = with(val_peek(3),val_peek(1)); }
+break;
+case 298:
 //#line 1100 "e.y"
-                    {
-                        reserved("on event");
-                    }
-                    break;
-                case 302:
-//#line 1107 "e.y"
-                    {
-                        yyval = mType(val_peek(1), list(), val_peek(0));
-                    }
-                    break;
-                case 303:
-//#line 1108 "e.y"
-                    {
-                        yyval = mType(val_peek(4), val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 304:
-//#line 1109 "e.y"
-                    {
-                        yyval = mType("run", val_peek(2), val_peek(0));
-                    }
-                    break;
-                case 305:
+{ yyval = list(val_peek(0)); }
+break;
+case 299:
+//#line 1101 "e.y"
+{ yyval = with(val_peek(3),val_peek(0)); }
+break;
+case 300:
+//#line 1103 "e.y"
+{ reserved("on event"); }
+break;
+case 301:
+//#line 1104 "e.y"
+{ reserved("on event"); }
+break;
+case 302:
+//#line 1111 "e.y"
+{ yyval = mType(val_peek(1),list(),val_peek(0)); }
+break;
+case 303:
+//#line 1112 "e.y"
+{ yyval = mType(val_peek(4),val_peek(2),val_peek(0)); }
+break;
+case 304:
 //#line 1113 "e.y"
-                    {
-                        yyval = val_peek(0);
-                    }
-                    break;
-                case 306:
-//#line 1114 "e.y"
-                    {
-                        yyval = val_peek(1);
-                    }
-                    break;
-                case 307:
+{ yyval = mType("run",val_peek(2),val_peek(0)); }
+break;
+case 305:
+//#line 1117 "e.y"
+{ yyval = val_peek(0); }
+break;
+case 306:
 //#line 1118 "e.y"
-                    {
-                        yyval = list(val_peek(0));
-                    }
-                    break;
-                case 308:
-//#line 1119 "e.y"
-                    {
-                        yyval = with(val_peek(3), val_peek(0));
-                    }
-                    break;
-                case 309:
-//#line 1126 "e.y"
-                    {
-                        yyval = pType(val_peek(1), val_peek(0));
-                    }
-                    break;
-                case 310:
-//#line 1127 "e.y"
-                    {
-                        yyval = pType(null, val_peek(0));
-                    }
-                    break;
-                case 311:
+{ yyval = val_peek(1); }
+break;
+case 307:
+//#line 1122 "e.y"
+{ yyval = list(val_peek(0)); }
+break;
+case 308:
+//#line 1123 "e.y"
+{ yyval = with(val_peek(3),val_peek(0)); }
+break;
+case 309:
+//#line 1130 "e.y"
+{ yyval = pType(val_peek(1),val_peek(0)); }
+break;
+case 310:
 //#line 1131 "e.y"
-                    {
-                        yyval = null;
-                    }
-                    break;
-                case 312:
-//#line 1132 "e.y"
-                    {
-                        yyval = val_peek(0);
-                    }
-                    break;
-                case 315:
-//#line 1148 "e.y"
-                    {
-                        begin();
-                    }
-                    break;
-                case 316:
-//#line 1155 "e.y"
-                    {
-                        end();
-                    }
-                    break;
-//#line 6801 "EParser.java"
+{ yyval = pType(null,val_peek(0)); }
+break;
+case 311:
+//#line 1135 "e.y"
+{ yyval = null; }
+break;
+case 312:
+//#line 1136 "e.y"
+{ yyval = val_peek(0); }
+break;
+case 315:
+//#line 1152 "e.y"
+{ begin(); }
+break;
+case 316:
+//#line 1159 "e.y"
+{ end(); }
+break;
+//#line 6766 "EParser.java"
 //########## END OF USER-SUPPLIED ACTIONS ##########
-            }//switch
-            //#### Now let's reduce... ####
-            if (yydebug) debug("reduce");
-            state_drop(yym);             //we just reduced yylen states
-            yystate = state_peek(0);     //get new state
-            val_drop(yym);               //corresponding value drop
-            yym = yylhs[yyn];            //select next TERMINAL(on lhs)
-            if (yystate == 0 && yym == 0)//done? 'rest' state and at first TERMINAL
-            {
-                debug("After reduction, shifting from state 0 to state " + YYFINAL + "");
-                yystate = YYFINAL;         //explicitly say we're done
-                state_push(YYFINAL);       //and save it
-                val_push(yyval);           //also save the semantic value of parsing
-                if (yychar < 0)            //we want another character?
-                {
-                    yychar = yylex();        //get next character
-                    if (yychar < 0) yychar = 0;  //clean, if necessary
-                    if (yydebug)
-                        yylexdebug(yystate, yychar);
-                }
-                if (yychar == 0)          //Good exit (if lex returns 0 ;-)
-                    break;                 //quit the loop--all DONE
-            }//if yystate
-            else                        //else not done yet
-            { //get next state and push, for next yydefred[]
-                yyn = yygindex[yym];      //find out where to go
-                if ((yyn != 0) && (yyn += yystate) >= 0 &&
-                  yyn <= YYTABLESIZE && yycheck[yyn] == yystate)
-                    yystate = yytable[yyn]; //get new state
-                else
-                    yystate = yydgoto[yym]; //else go to new defred
-                debug("after reduction, shifting from state " + state_peek(0) + " to state " + yystate + "");
-                state_push(yystate);     //going again, so push state & val...
-                val_push(yyval);         //for next action
-            }
-        }//main loop
-        return 0;//yyaccept!!
-    }
+    }//switch
+    //#### Now let's reduce... ####
+    if (yydebug) debug("reduce");
+    state_drop(yym);             //we just reduced yylen states
+    yystate = state_peek(0);     //get new state
+    val_drop(yym);               //corresponding value drop
+    yym = yylhs[yyn];            //select next TERMINAL(on lhs)
+    if (yystate == 0 && yym == 0)//done? 'rest' state and at first TERMINAL
+      {
+      debug("After reduction, shifting from state 0 to state "+YYFINAL+"");
+      yystate = YYFINAL;         //explicitly say we're done
+      state_push(YYFINAL);       //and save it
+      val_push(yyval);           //also save the semantic value of parsing
+      if (yychar < 0)            //we want another character?
+        {
+        yychar = yylex();        //get next character
+        if (yychar<0) yychar=0;  //clean, if necessary
+        if (yydebug)
+          yylexdebug(yystate,yychar);
+        }
+      if (yychar == 0)          //Good exit (if lex returns 0 ;-)
+         break;                 //quit the loop--all DONE
+      }//if yystate
+    else                        //else not done yet
+      {                         //get next state and push, for next yydefred[]
+      yyn = yygindex[yym];      //find out where to go
+      if ((yyn != 0) && (yyn += yystate) >= 0 &&
+            yyn <= YYTABLESIZE && yycheck[yyn] == yystate)
+        yystate = yytable[yyn]; //get new state
+      else
+        yystate = yydgoto[yym]; //else go to new defred
+      debug("after reduction, shifting from state "+state_peek(0)+" to state "+yystate+"");
+      state_push(yystate);     //going again, so push state & val...
+      val_push(yyval);         //for next action
+      }
+    }//main loop
+  return 0;//yyaccept!!
+}
 //## end of method parse() ######################################
 
 
-}
 
+}
 //################### END OF CLASS yaccpar ######################



1.5       +3 -0      e/src/jsrc/org/erights/e/elang/syntax/PrettyFeeder.java

Index: PrettyFeeder.java
===================================================================
RCS file: /cvs/e/src/jsrc/org/erights/e/elang/syntax/PrettyFeeder.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- PrettyFeeder.java	2001/11/11 23:32:17	1.4
+++ PrettyFeeder.java	2001/12/02 18:42:01	1.5
@@ -23,6 +23,9 @@
 
 import org.erights.e.elib.tables.FlexList;
 import org.erights.e.elib.tables.Twine;
+import org.quasiliteral.syntax.LineFeeder;
+import org.quasiliteral.syntax.TwineFeeder;
+import org.quasiliteral.syntax.NeedMoreException;
 
 import java.io.IOException;
 



1.5       +1 -0      e/src/jsrc/org/erights/e/elang/syntax/QuasiFeeder.java

Index: QuasiFeeder.java
===================================================================
RCS file: /cvs/e/src/jsrc/org/erights/e/elang/syntax/QuasiFeeder.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- QuasiFeeder.java	2001/11/10 19:40:42	1.4
+++ QuasiFeeder.java	2001/12/02 18:42:01	1.5
@@ -20,6 +20,7 @@
 */
 
 import org.erights.e.elib.tables.Twine;
+import org.quasiliteral.syntax.LineFeeder;
 
 import java.io.IOException;
 



1.96      +13 -46    e/src/jsrc/org/erights/e/elang/syntax/e.y

Index: e.y
===================================================================
RCS file: /cvs/e/src/jsrc/org/erights/e/elang/syntax/e.y,v
retrieving revision 1.95
retrieving revision 1.96
diff -u -r1.95 -r1.96
--- e.y	2001/12/01 10:38:41	1.95
+++ e.y	2001/12/02 18:42:01	1.96
@@ -29,13 +29,8 @@
 %{
 package org.erights.e.elang.syntax;
 
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.ObjectInput;
-import java.io.ObjectInputStream;
 import org.erights.build.EYaccFixer;
 import org.erights.e.develop.exception.ThrowableSugar;
-import org.erights.e.elang.evm.EExpr;
 import org.erights.e.elang.evm.ENode;
 import org.erights.e.elang.interp.Interp;
 import org.erights.e.elib.base.Ejector;
@@ -45,7 +40,15 @@
 import org.erights.e.elib.tables.IdentityCacheTable;
 import org.erights.e.elib.tables.IntTable;
 import org.erights.e.elib.tables.Twine;
+import org.quasiliteral.astro.AstroSchema;
 import org.quasiliteral.astro.AstroToken;
+import org.quasiliteral.astro.BaseSchema;
+import org.quasiliteral.syntax.SyntaxException;
+
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.ObjectInput;
+import java.io.ObjectInputStream;
 %}
 
 /* Categorical terminals */
@@ -147,6 +150,7 @@
 /* Grammar follows */
 %%
 
+
 /** 
  * JAY - added EOLs to start production so we can accept
  * "comment-only" programs.
@@ -1179,8 +1183,10 @@
  |      VALUETYPE | VIRTUAL | VOLATILE | WSTRING 
  ;
 
+
 %%
 
+
 /**
  *
  */
@@ -1639,48 +1645,9 @@
 
 /**
  *
- */
-static public ConstList getTokenNames() {
-    return ConstList.fromArray(TheTokens);
-}
-
-/**
- *
  */
-static private IntTable TheTokenTable = null;
-
-/**
- *
- */
-static private IntTable getTokenTable() {
-    if (null == TheTokenTable) {
-        TheTokenTable = new IntTable(String.class);
-        for (int i = 0; i < TheTokens.length; i++) {
-            if (TheTokens[i] != null) {
-                TheTokenTable.putInt(TheTokens[i], i, true);
-            }
-        }
-    }
-    return TheTokenTable;
-}
-
-/**
- * If 'name' is a keyword, return it's token type code, else -1.
- * <p>
- * Note that E keywords are case insensitive, so 'name' is first
- * toLowerCase()d. 
- */
-static public int optKeywordType(String name) {
-    name = name.toLowerCase();
-    return getTokenTable().getInt(name, -1);
-}
-
-/**
- *
- */
-static public ConstMap getTokenMap() {
-    return getTokenTable().snapshot();
-}
+static public final AstroSchema DEFAULT_SCHEMA =
+  new BaseSchema(ConstList.fromArray(TheTokens));
 
 /**
  * These are the tokens that may appear at the end of a line, in which



1.44      +2 -2      e/src/jsrc/org/erights/e/ui/elmer/EInterpAdapter.java

Index: EInterpAdapter.java
===================================================================
RCS file: /cvs/e/src/jsrc/org/erights/e/ui/elmer/EInterpAdapter.java,v
retrieving revision 1.43
retrieving revision 1.44
diff -u -r1.43 -r1.44
--- EInterpAdapter.java	2001/12/02 06:01:50	1.43
+++ EInterpAdapter.java	2001/12/02 18:42:02	1.44
@@ -23,8 +23,8 @@
 import org.erights.e.develop.format.StringHelper;
 import org.erights.e.elang.interp.InteractiveInterp;
 import org.erights.e.elang.interp.InterpLoop;
-import org.erights.e.elang.syntax.NeedMoreException;
-import org.erights.e.elang.syntax.TwineFeeder;
+import org.quasiliteral.syntax.NeedMoreException;
+import org.quasiliteral.syntax.TwineFeeder;
 import org.erights.e.elib.base.SourceSpan;
 import org.erights.e.elib.eio.TextWriter;
 import org.erights.e.elib.prim.FERunner;



1.4       +12 -0     e/src/jsrc/org/quasiliteral/astro/AstroSchema.java

Index: AstroSchema.java
===================================================================
RCS file: /cvs/e/src/jsrc/org/quasiliteral/astro/AstroSchema.java,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- AstroSchema.java	2001/12/02 06:01:50	1.3
+++ AstroSchema.java	2001/12/02 18:42:02	1.4
@@ -32,9 +32,21 @@
 
     /**
      * Returns the tag represented by this type code in the grammar described
+     * by this schema, or null.
+     */
+    AstroTag getOptTagForCode(int typeCode);
+
+    /**
+     * Returns the tag represented by this type code in the grammar described
      * by this schema
      */
     AstroTag getTagForCode(int typeCode);
+
+    /**
+     * Returns the tag represented by this type name in the grammar described
+     * by this schema, or null
+     */
+    AstroTag getOptTagForName(String typeName);
 
     /**
      * Returns the tag represented by this type name in the grammar described



1.4       +22 -6     e/src/jsrc/org/quasiliteral/astro/BaseSchema.java

Index: BaseSchema.java
===================================================================
RCS file: /cvs/e/src/jsrc/org/quasiliteral/astro/BaseSchema.java,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- BaseSchema.java	2001/12/02 06:01:50	1.3
+++ BaseSchema.java	2001/12/02 18:42:02	1.4
@@ -82,19 +82,35 @@
     /**
      *
      */
+    public AstroTag getOptTagForCode(int typeCode) {
+        AstroTag optResult = myByTypeCodes[typeCode];
+        return optResult;
+    }
+
+    /**
+     *
+     */
     public AstroTag getTagForCode(int typeCode) {
-        AstroTag result = myByTypeCodes[typeCode];
-        E.requireSI(null != result, "No tag for type code: ", typeCode);
-        return result;
+        AstroTag optResult = myByTypeCodes[typeCode];
+        E.requireSI(null != optResult, "No tag for type code: ", typeCode);
+        return optResult;
+    }
+
+    /**
+     *
+     */
+    public AstroTag getOptTagForName(String typeName) {
+        AstroTag optResult = (AstroTag)myByTypeName.get(typeName, null);
+        return optResult;
     }
 
     /**
      *
      */
     public AstroTag getTagForName(String typeName) {
-        AstroTag result = (AstroTag)myByTypeName.get(typeName, null);
-        E.require(null != result, "No tag named: ", typeName);
-        return result;
+        AstroTag optResult = (AstroTag)myByTypeName.get(typeName, null);
+        E.require(null != optResult, "No tag named: ", typeName);
+        return optResult;
     }
 
     /**



1.1                  e/src/jsrc/org/quasiliteral/syntax/BaseLexer.java

Index: BaseLexer.java
===================================================================
package org.quasiliteral.syntax;

import org.erights.e.elib.tables.Twine;
import org.quasiliteral.astro.AstroSchema;
import org.quasiliteral.astro.AstroToken;

import java.io.IOException;
import java.math.BigInteger;

//This file is hereby placed in the public domain

/**
 * To be replaced with a lexer based on Antlr.
 * <p>
 * Abstracts out common elements of lexers usable within the E quasi-parsing
 * framework.
 *
 * @author <a href="mailto:markm@caplet.com">Mark Miller</a>
 */
public abstract class BaseLexer {

    /**
     *
     */
    static public final int EOFCHAR = -1;

    /** contains all lines after the current line */
    protected LineFeeder myInput;

    /** the current line, or null at end-of-file */
    public Twine myLTwine = null;

    /** the string part, but as an array for speed */
    public char[] myLData = null;

    /** position in current line of candidate character */
    protected int myPos;

    /** the candidate character, or EOFCHAR for end-of-file. */
    protected int myChar;

    /**
     * Where on the current line does the current token start?  If the token
     * starts before the current line, or if there is no current token, this
     * is -1.
     */
    protected int myOptStartPos = -1;

    /**
     * Accumulates all text of the current token from lines before the
     * current line, or null if no current token or if the current
     * token starts on the current line.  The EOL token itself is not
     * considered to be a line spanning token.
     */
    protected Twine myOptStartText = null;

    /**
     * Is there a nextChar() that's been delayed?
     */
    protected boolean myDelayedNextChar = false;

    /**
     *
     */
    protected boolean myPartialFlag;

    /**
     * Should tabs be rejected as valid whitespace?
     */
    protected boolean myNoTabsFlag;

    /**
     * Keeps track of indentation level
     */
    protected Indenter myIndenter;

    /**
     * Should the next line get extra indentation as a continuation line?
     */
    protected boolean myContinueFlag;

    /**
     *
     */
    protected AstroSchema mySchema;

    /**
     *
     */
    public BaseLexer(LineFeeder input,
                     boolean partialFlag,
                     boolean noTabsFlag,
                     AstroSchema schema)
      throws IOException {

        myInput = input;
        myPos = -1;
        myPartialFlag = partialFlag;
        myLTwine = myInput.optNextLine(false, 0, 'x', 0);
        if (null == myLTwine) {
            myLData = null;
        } else {
            myLData = myLTwine.bare().toCharArray();
        }
        nextChar();
        myNoTabsFlag = noTabsFlag;
        myIndenter = new Indenter();
        myContinueFlag = false;
        mySchema = schema;
    }

    /**
     * Does not affect the partial flag
     */
    public void setSource(Twine newSource) {
        TwineFeeder feeder = new TwineFeeder(newSource);

        myInput = feeder;
        myPos = -1;
        // myPartialFlag = ??;
        myLTwine = feeder.optNextLine(false, 0, 'x', 0);
        if (null == myLTwine) {
            myLData = null;
        } else {
            myLData = myLTwine.bare().toCharArray();
        }
        myOptStartPos = -1;
        myOptStartText = null;
        myDelayedNextChar = true; //rather than doing nextChar() ourselves
        myIndenter = new Indenter();
        myContinueFlag = false;
    }

    /**
     * Skip to the end of this line, so that the next character read will be
     * from the next line, forget any token we may have been in the midst
     * of, and reset our indentation tracker.
     */
    protected void reset() {
        if (null != myLTwine) {
            myPos = myLData.length;
        }
        myOptStartPos = -1;
        myOptStartText = null;
        myDelayedNextChar = true;
        myIndenter = new Indenter();
        myContinueFlag = false;
    }

    /**
     *
     */
    protected void nextLine() throws IOException {
        if (myLTwine == null) {
            myChar = EOFCHAR;
            return;
        }
        if (-1 == myOptStartPos) {
            if (null == myOptStartText) {
                //no current token, do nothing
            } else {
                //current token already started
                myOptStartText = (Twine)myOptStartText.add(myLTwine);
            }
        } else {
            //current token started on this line at myOptStartPos
            myOptStartText = (Twine)myLTwine.run(myOptStartPos,
                                                 myLTwine.size());
            myOptStartPos = -1;
        }
        myPos = -1;

        //This is irritatingly redundant with needMore(..).
        //XXX Need to refactor, but how?
        char closer = myIndenter.getCloser();
        int indent = myIndenter.getIndent();
        if (myContinueFlag) {
            indent += 2;
        }
        myLTwine =
          myInput.optNextLine(('"' == closer || '`' == closer),
                              indent,
                              closer,
                              myIndenter.getCloseIndent());

        if (null == myLTwine) {
            //don't clear myContinueFlag on end-of-file
            myLData = null;
        } else {
            myContinueFlag = false;
            myLData = myLTwine.bare().toCharArray();
        }
        myChar = '\n';
    }

    /**
     *
     */
    protected void nextChar() throws IOException {
        while (true) {
            if (null == myLTwine) {
                myChar = EOFCHAR;
                return;
            }
            myPos++;
            int len = myLData.length;
            if (myPos < len) {
                myChar = myLData[myPos];
                return;
            } else {
                nextLine();
            }
        }
    }

    /**
     *
     */
    protected abstract boolean isContinuer(int tokenType);

    /**
     *
     */
    public AstroToken nextToken() throws IOException, SyntaxException {
        AstroToken result;
        try {
            result = getNextToken();
        } finally {
            myOptStartPos = -1;
            myOptStartText = null;
        }
        if (isContinuer(result.getType())) {
            return continuer(result);
        } else {
            return result;
        }
    }

    /**
     * Separated out for use by '>'
     */
    protected AstroToken continuer(AstroToken result) throws IOException {
        if (isWhite(myPos, myLData.length)) {
            myContinueFlag = true;
            skipLine();
        }
        return result;
    }

    /**
     * Throws a {@link SyntaxException} that also captures the current line
     * and position as the position of the error.
     */
    public void syntaxError(String msg) throws SyntaxException {
        int start = myOptStartPos;
        if (-1 == start) {
            start = myPos - 1;
        }
        start = Math.max(Math.min(start, myPos - 1), 0);
        int bound = Math.max(myPos, start + 1);
        SyntaxException sex = new SyntaxException(msg,
                                                  myLTwine,
                                                  start,
                                                  bound);
        reset();
        throw sex;
    }

    /**
     * Called when input was otherwise well formed, but ran out, so more is
     * needed.
     * <p>
     * Normally, this just turns into an equivalent 'syntaxError(msg)'.  But,
     * if the partial flag is set, meaning that the client wants to prompt
     * intelligently for more input, then this throws a
     * {@link NeedMoreException} that explains at what indentation the next
     * input is expected.
     */
    public void needMore(String msg)
      throws NeedMoreException, SyntaxException {
        if (myPartialFlag) {

            //This is irritatingly redundant with nextLine().
            //XXX Need to refactor, but how?
            char closer = myIndenter.getCloser();
            int indent = myIndenter.getIndent();
            if (myContinueFlag) {
                indent += 2;
                myContinueFlag = false;
            }
            NeedMoreException nme =
              new NeedMoreException(msg,
                                    ('"' == closer || '`' == closer),
                                    indent,
                                    closer,
                                    myIndenter.getCloseIndent());
            reset();
            throw nme;
        } else {
            syntaxError(msg);
        }
    }

    /**
     *
     */
    private boolean eatDigit(int radix) throws IOException {
        if (Character.digit((char)myChar, radix) != -1 || myChar == '_') {
            nextChar();
            return true;
        } else {
            return false;
        }
    }

    /**
     *
     */
    protected void skipWhiteSpace() throws IOException {
        while (true) {
            if (myChar == EOFCHAR) {
                return;
            }
            if (Character.isWhitespace((char)myChar)) {
                if (myChar == '\n') {
                    return;
                }
                if (myChar == '\t') {
                    if (myNoTabsFlag) {
                        syntaxError
                          ("The optional e.enable.notabs feature" +
                           " in eprops.txt is currently on,\n" +
                           "so tabs are not considered valid whitespace");
                    }
                    //else, we should warn, but XXX we don't yet have a
                    //warning mechanism.
                }
                nextChar();
            } else {
                if ((myChar == '?' || myChar == '>') && isWhite(0, myPos)) {
                    //Is the first non-whitespace character on this line a
                    //'?' or '>'?
                    //If yes, so treat it as an updoc line
                    skipLine();
                } else {
                    //If not, treat it normally.
                    return;
                }
            }
        }
    }

    /**
     * Are all the characters on the current line from start inclusive to
     * bound exclusive whitespace characters?
     */
    protected boolean isWhite(int start, int bound) {
        for (int i = start; i < bound; i++) {
            if (!Character.isWhitespace(myLData[i])) {
                return false;
            }
        }
        return true;
    }

    /**
     *
     */
    protected AstroToken leafTag(int typeCode, Twine source) {
        return (AstroToken)mySchema.leafTag(typeCode, source);
    }

    /**
     *
     */
    protected AstroToken leafData(Object data, Twine source) {
        return (AstroToken)mySchema.leafData(data, source);
    }

    /**
     *
     */
    protected AstroToken composite(int typeCode, Object data, Twine source) {
        return (AstroToken)mySchema.composite(typeCode, data, source);
    }

    /**
     *
     */
    protected abstract AstroToken getNextToken()
      throws IOException, SyntaxException;

    /**
     *
     */
    protected AstroToken openBracket(char closer) throws IOException {
        int tokenType = myChar;
        nextChar();
        Twine openner = endToken();
        return openBracket(tokenType, openner, closer);
    }

    /**
     *
     */
    protected AstroToken openBracket(int tokenType,
                                     Twine openner,
                                     char closer)
      throws IOException {
        if (isWhite(myPos, myLData.length)) {
            myIndenter.nest(openner, closer);
        } else {
            //Indent the next line to right after the open.
            myIndenter.push(openner, closer, myPos);
        }
        return leafTag(tokenType, openner);
    }

    /**
     *
     */
    protected AstroToken closeBracket() throws IOException {
        char closerChar = (char)myChar;
        nextChar();
        Twine closer = endToken();
        //on mismatched close, throws SyntaxError at openner
        //on unmatched close, throws Syntax error at closer
        myIndenter.pop(closerChar, closer);
        return leafTag(closerChar, closer);
    }

    /**
     *
     */
    protected char charConstant() throws IOException, SyntaxException {
        if (myChar == '\\') {
            nextChar();
            switch (myChar) {
                case 'b':
                    return '\b';
                case 't':
                    return '\t';
                case 'n':
                    return '\n';
                case 'f':
                    return '\f';
                case 'r':
                    return '\r';
                case '"':
                    return '"';
                case '\'':
                    return '\'';
                case '\\':
                    return '\\';
                case '\n':
                    {
                        //XXX need to move into stringLiteral only
                        //XXX bug: must be accepted at end of string
                        nextChar();
                        return charConstant();
                    }
                case EOFCHAR:
                    {
                        syntaxError("End of file in middle of literal");
                    }
                case 'u':
                    {
                        syntaxError
                          ("XXX escaped uchar codes not yet implemented");
                    }
                default:
                    {
                        if (Character.isDigit((char)myChar)) {
                            syntaxError
                              ("XXX escaped char codes not yet implemented");
                        } else {
                            syntaxError("Unrecognized escaped character");
                        }
                    }
            }
        } else if (myChar == EOFCHAR) {
            syntaxError("End of file in middle of literal");
        } else {
            return (char)myChar;
        }
        return 'x'; //keep compiler happy
    }

    /**
     *
     */
    protected AstroToken charLiteral() throws IOException, SyntaxException {
        nextChar();
        char value = charConstant();
        nextChar();
        if (myChar != '\'') {
            syntaxError("char constant must end in \"'\"");
        }
        nextChar();
        return leafData(new Character(value), endToken());
    }

    /**
     * The first character of an E identifier may be anything accepted
     * as the first character of a Java identifier except '$'.  I.e.,
     * a letter or '_'.
     *
     * @see java.lang.Character#isJavaIdentifierStart
     */
    static public boolean isIdentifierStart(char ch) {
        return Character.isJavaIdentifierStart(ch) && ch != '$';
    }

    /**
     * A non-first character of an E identifier may be anything
     * accepted as a non-first character of a Java identifier except
     * '$'. The ascii subset consists of letters, digits, and '_'.
     * See Character.isJavaIdentifierPart() for the full spec.
     *
     * @see java.lang.Character#isJavaIdentifierPart
     */
    static public boolean isIdentifierPart(char ch) {
        return Character.isJavaIdentifierPart(ch) && ch != '$';
    }

    /**
     * A legal E identifier or keyword is a string whose first character
     * isIdentifierStart, the rest of whose characters are
     * isIdentifierPart.
     */
    static public boolean isIdentifierOrKeyword(String str) {
        int len = str.length();
        if (len == 0) {
            return false;
        } else if (!isIdentifierStart(str.charAt(0))) {
            return false;
        } else {
            for (int i = 1; i < len; i++) {
                if (!isIdentifierPart(str.charAt(i))) {
                    return false;
                }
            }
            return true;
        }
    }

    /** pretty self explanatory */
    public boolean isEndOfFile() {
        return null == myLTwine;
    }

    /**
     *
     */
    protected AstroToken numberLiteral()
      throws IOException, SyntaxException {
        // Now handles floating point numbers as well as integers
        boolean floating = false;
        int radix = 10;
        if (myChar == '0') {
            radix = 8;
            nextChar();
            if (myChar == 'x' || myChar == 'X') {
                radix = 16;
                nextChar();
            }
        }
        if (radix == 16) {
            while (eatDigit(16)) {
            }
        } else {
            //even if radix == 8, we may instead have a floating point literal
            while (eatDigit(10)) {
            }
            // If we have a decimal point go for the fractional part
            if (myChar == '.' && !peekChar('.')) {
                nextChar();
                floating = true;
                while (eatDigit(10)) {
                }
            }

            if ((myChar == 'E') || (myChar == 'e')) {
                nextChar();
                floating = true;
                if (myChar == '-') {
                    nextChar();
                }
                while (eatDigit(10)) {
                }
            }
        }
        Twine tok = endToken();
        String str = tok.replaceAll("_", "").bare();
        if (floating) {
            return leafData(Double.valueOf(str), tok);
        } else {
            if (radix == 16) {
                //remove the leading "0x" to make BigInteger happy
                str = str.substring(2);
            }
            return leafData(new BigInteger(str, radix), tok);
        }
    }

    /**
     * XXX Get rid of peekChar/0 or make it work
     */
    protected char peekChar() {
        if (myChar == EOFCHAR || myChar == '\n') {
            throw new Error("internal: can't peek here");
        }
        int last = myLData.length - 1;

        if (myPos < last) {
            return myLData[myPos + 1];
        } else {
            throw new Error("internal: (XXX bug) peek past end");
        }
    }

    /**
     *
     */
    protected boolean peekChar(char c) {
        if (myChar == EOFCHAR || myChar == '\n') {
            throw new Error("internal: can't peek here");
        }
        int last = myLData.length - 1;

        if (myPos < last) {
            return c == myLData[myPos + 1];
        } else {
            return false;
        }
    }

    /**
     * Skip to the rest of this line.
     */
    protected void skipLine() throws IOException {
        if (null != myLTwine) {
            myPos = myLData.length - 1;
            myChar = myLData[myPos];
        }
        myDelayedNextChar = true;
    }

    /**
     *
     */
    protected void startToken() {
        if (-1 != myOptStartPos || null != myOptStartText) {
            throw new Error("internal: token already started");
        }
        myOptStartPos = myPos;
    }

    /**
     * Cancels a started token
     */
    protected void stopToken() {
        myOptStartPos = -1;
        myOptStartText = null;
    }

    /**
     *
     */
    protected Twine endToken() {
        Twine result;
        int pos = myPos;
        if (myDelayedNextChar) {
            pos++;
        }
        if (-1 == myOptStartPos) {
            if (null == myOptStartText) {
                throw new Error("internal: no current token");
            } else {
                //started on previous line
                result = myOptStartText;
                if (null != myLTwine) {
                    result = (Twine)result.add(myLTwine.run(0, pos));
                }
            }
        } else {
            //starts on this line
            result = (Twine)myLTwine.run(myOptStartPos, pos);
        }
        stopToken();
        return result;
    }

    /**
     *
     */
    protected AstroToken stringLiteral() throws IOException, SyntaxException {
        nextChar();
        Twine openner = (Twine)myLTwine.run(myOptStartPos, myPos);
        myIndenter.push(openner, '"', 0);
        StringBuffer value = new StringBuffer();
        while (myChar != '"') {
            if (myChar == EOFCHAR) {
                needMore("File ends inside string literal");
            }
            value.append(charConstant());
            nextChar();
        }
        nextChar();
        Twine closer = endToken();
        myIndenter.pop('"', closer);
        return leafData(value.toString(), closer);
    }
}



1.1                  e/src/jsrc/org/quasiliteral/syntax/FileFeeder.java

Index: FileFeeder.java
===================================================================
package org.quasiliteral.syntax;

/*
The contents of this file are subject to the Electric Communities E Open
Source Code License Version 1.0 (the "License"); you may not use this file
except in compliance with the License. You may obtain a copy of the License
at http://www.communities.com/EL/.

Software distributed under the License is distributed on an "AS IS" basis,
WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for
the specific language governing rights and limitations under the License.

The Original Code is the Distributed E Language Implementation, released
July 20, 1998.

The Initial Developer of the Original Code is Electric Communities.
Copyright (C) 1998 Electric Communities. All Rights Reserved.

Contributor(s): ______________________________________.
*/

import org.erights.e.develop.format.StringHelper;
import org.erights.e.elib.base.SourceSpan;
import org.erights.e.elib.eio.TextWriter;
import org.erights.e.elib.tables.Twine;

import java.io.BufferedReader;
import java.io.IOException;

/**
 * A FileFeeder reads its input from a Reader which it assumes starts at the
 * beginning of line 1 in the text unit (file?) described by the Url.
 *
 * @author <a href="mailto:markm@erights.org">Mark S. Miller</a>
 */
public class FileFeeder implements LineFeeder {

    private String myUrl;

    private int myLineNum;

    private BufferedReader myOptReader;

    private TextWriter myOptOuts;

    /**
     *
     */
    public FileFeeder(String url,
                      BufferedReader optReader,
                      TextWriter optOuts) {
        myUrl = url;
        myLineNum = 0; //haven't read anything yet
        myOptReader = optReader;
        myOptOuts = optOuts;
    }

    /**
     *
     */
    public Twine optNextLine(boolean quoted,
                             int indent,
                             char closer,
                             int closeIndent)
      throws IOException {
        if (myOptReader == null) {
            return null;
        }
        if (myOptOuts != null) {
            myOptOuts.print(prompt(quoted,
                                   indent,
                                   closer,
                                   closeIndent));
            myOptOuts.flush();
        }
        //XXX thread blockage point:
        String optResultStr = myOptReader.readLine();
        myLineNum++;

        if (null == optResultStr) {
            myOptReader.close();
            myOptReader = null;

        } else {
            optResultStr += "\n";
        }
        if (null == optResultStr) {
            return null;
        }
        SourceSpan span = new SourceSpan(myUrl, true,
                                         myLineNum,
                                         0,
                                         myLineNum,
                                         optResultStr.length() - 1);
        return Twine.fromString(optResultStr, span);
    }

    /**
     *
     */
    private String prompt(boolean quoted,
                          int indent,
                          char closer,
                          int closeIndent) {
        if (quoted) {
            return "> ";
        } else if (0 == indent) {
            return "? ";
        } else {
            int reps = Math.max(0, Math.min(indent, closeIndent));
            return "> " + StringHelper.multiply(" ", reps);
        }
    }
}



1.1                  e/src/jsrc/org/quasiliteral/syntax/Indenter.java

Index: Indenter.java
===================================================================
package org.quasiliteral.syntax;

/*
The contents of this file are subject to the Improvements to the
Distributed E Language Implementation License Version 1.0 (the
"License"); you may not use this file except in compliance with the
License. You may obtain a copy of the License at
http://www.erights.org/download/mmlicense.html

Software distributed under the License is distributed on an "AS IS"
basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
the License for the specific language governing rights and limitations
under the License.

The Original Code is the Improvements to the Distributed E Language
Implementation, released May 27, 1999.

The Initial Developer of the Original Code is Mark S. Miller.
Copyright (C) 1999 Mark S. Miller. All Rights Reserved.

Contributor(s): ______________________________________.
*/

import org.erights.e.elib.tables.Twine;

import java.lang.reflect.Array;

/**
 * Keeps track of indentation info for ELexer and clients.
 * <p>
 * Should be made package scope, but made public for now to enable unit
 * testing by updoc.
 *
 * @author <a href="mailto:markm@caplet.com">Mark S Miller</a>
 * @author <a href="mailto:tstanley@cocoon.com">Terry Stanley</a>
 */
public class Indenter {

    /**
     * How many block-levels deep am I?
     * <p>
     * Each open-bracketing character at the end of a line introduces a new
     * nesting level.  Each nesting level counts for four spaces.
     */
    private int myNest;

    /**
     * My top-of-stack is the same as the number of unclosed open bracketing
     * characters.
     * <p>
     * The stack keeps track of unclosed open brackets, and what
     * indent should be assigned to new lines within that bracket (should it
     * be the most recent -- the top of stack).
     */
    private int myTOS;

    /**
     * The openners are Twine for reporting located errors at close time
     */
    private Twine[] myOpennerStack;

    /**
     * The closers -- close bracketing characters that would close the
     * currently unclosed open brackets
     * <p>
     * We start the stack off with an indent level of zero and a dummy closer
     * character.
     */
    private char[] myCloserStack;

    /**
     * The indentation level associated with each unclosed open bracket
     */
    private int[] myIndentStack;

    /**
     * Was this open bracket also a nesting?
     * <p>
     * I.e., was the openner the last character on its line?  If so, then
     * its popping should also decrement myNest.
     */
    private boolean[] myNestStack;

    /**
     *
     */
    public Indenter() {
        myNest = 0;
        myTOS = 0;
        myOpennerStack = new Twine[16];
        myOpennerStack[0] = null;       //dummy initial openner
        myCloserStack = new char[16];
        myCloserStack[myTOS] = 'x';     // dummy initial closer
        myIndentStack = new int[16];
        myIndentStack[myTOS] = 0;
        myNestStack = new boolean[16];
        myNestStack[myTOS] = true; //shouldn't matter, can't be popped
    }

    /**
     *
     */
    private Object grow(Object array) {
        Class memType = array.getClass().getComponentType();
        int length = Array.getLength(array);
        Object result = Array.newInstance(memType, length * 2);
        System.arraycopy(array, 0, result, 0, length);
        return result;
    }

    /**
     * Internal push
     */
    private void push(Twine openner,
                      char closerChar,
                      int indent,
                      boolean isNest) {
        myTOS++;
        if (myTOS >= myCloserStack.length) {
            myOpennerStack = (Twine[])grow(myOpennerStack);
            myCloserStack = (char[])grow(myCloserStack);
            myIndentStack = (int[])grow(myIndentStack);
            myNestStack = (boolean[])grow(myNestStack);
        }
        myOpennerStack[myTOS] = openner;
        myCloserStack[myTOS] = closerChar;
        myIndentStack[myTOS] = indent;
        myNestStack[myTOS] = isNest;
    }

    /**
     * Push a nester
     */
    public void nest(Twine openner, char closerChar) {
        myNest++;
        push(openner, closerChar, myNest * 4, true);
    }

    /**
     * Push a non-nester
     */
    public void push(Twine openner, char closerChar, int indent) {
        push(openner, closerChar, indent, false);
    }

    /**
     * Process a closing bracket by popping the stacks.
     * <p>
     * If the opening was also a nesting, this decrements the nest level.
     *
     * @param closerChar As an error check, 'closerChar' must be the closing
     *                   bracket character needed to close the most recent
     *                   unclosed bracket.
     * @param closer Used by some syntax errors to report where the erronous
     *               closing text occurs.
     */
    public void pop(char closerChar, Twine closer) {
        if (myTOS <= 0) {
            throw new SyntaxException
              ("unmatched closing bracket: " + closerChar,
               closer, 0, closer.size());
        }
        if (myCloserStack[myTOS] != closerChar) {
            Twine openner = myOpennerStack[myTOS];
            throw new SyntaxException
              ("mismatch: " + myCloserStack[myTOS] + " vs " + closerChar,
               openner, 0, openner.size());
        }
        int oldTOS = myTOS;
        myTOS--;
        if (myNestStack[oldTOS]) {
            myNest--;
        }
    }

    /**
     * How indented should a vanilla new line be in this context?
     * <p>
     * A vanilla new line is one that doesn't begin with a close bracketing
     * character (for these, use pop()'s return value), and one that's not
     * continuing a previous line by virtue of a binary operator or a
     * backslash
     */
    public int getIndent() {
        return myIndentStack[myTOS];
    }

    /**
     * Which character would close the most recent open bracket?
     */
    public char getCloser() {
        return myCloserStack[myTOS];
    }

    /**
     * If the character that would close the most recently open bracket
     * (getCloser()) were typed, where should it be indented?
     */
    public int getCloseIndent() {
        if (myNestStack[myTOS]) {
            return (myNest - 1) * 4;
        } else {
            return myIndentStack[myTOS] - 1;
        }
    }

    /**
     * Show closing stack
     */
    public String toString() {
        return new String(myCloserStack, 1, myTOS);
    }
}



1.1                  e/src/jsrc/org/quasiliteral/syntax/LineFeeder.java

Index: LineFeeder.java
===================================================================
package org.quasiliteral.syntax;

/*
The contents of this file are subject to the Electric Communities E Open
Source Code License Version 1.0 (the "License"); you may not use this file
except in compliance with the License. You may obtain a copy of the License
at http://www.communities.com/EL/.

Software distributed under the License is distributed on an "AS IS" basis,
WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for
the specific language governing rights and limitations under the License.

The Original Code is the Distributed E Language Implementation, released
July 20, 1998.

The Initial Developer of the Original Code is Electric Communities.
Copyright (C) 1998 Electric Communities. All Rights Reserved.

Contributor(s): ______________________________________.
*/

import org.erights.e.elib.tables.Twine;

import java.io.IOException;

/**
 * Where the lexer gets its input from, one line of Twine at a time.  <p>
 *
 * @author <a href="mailto:markm@erights.org">Mark S. Miller</a>
 */
public interface LineFeeder {

    /**
     * Returns either a Twine containing the next line of input (and
     * presumably memory of where it came from), or null meaning end of
     * input (EOF).  The parameters are for indentation-smart prompting or
     * pretty printing.
     *
     * @param quoted Will this next line be taken as literal text?  If so,
     *               then it should not be trimmed or indented.  'quoted' is
     *               true between double quotes, or between quasi-quotes when
     *               not inside a $ or @ hole.
     * @param indent The suggested indentation level for the next line,
     *               unless the next line begins with closer.
     * @param closer The character that would close the most recent unclosed
     *               openner.
     * @param closeIndent The suggested indentation level for the next line
     *                    if it does begin (after trimming) with closer.
     */
    Twine optNextLine(boolean quoted,
                      int indent,
                      char closer,
                      int closeIndent)
      throws IOException;
}



1.1                  e/src/jsrc/org/quasiliteral/syntax/NeedMoreException.java

Index: NeedMoreException.java
===================================================================
package org.quasiliteral.syntax;

/*
The contents of this file are subject to the Electric Communities E Open
Source Code License Version 1.0 (the "License"); you may not use this file
except in compliance with the License. You may obtain a copy of the License
at http://www.communities.com/EL/.

Software distributed under the License is distributed on an "AS IS" basis,
WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for
the specific language governing rights and limitations under the License.

The Original Code is the Distributed E Language Implementation, released
July 20, 1998.

The Initial Developer of the Original Code is Electric Communities.
Copyright (C) 1998 Electric Communities. All Rights Reserved.

Contributor(s): ______________________________________.
*/

/**
 * Thrown if the input end sooner than expected, to suggest how much the
 * next line of input should be indented.
 *
 * @author <a href="mailto:markm@erights.org">Mark S. Miller</a>
 */
public class NeedMoreException extends RuntimeException {

    private boolean myQuoted;

    private int myIndent;

    private char myCloser;

    private int closeIndent;

    /**
     * After msg, the remaining parameters are the same as for {@link
     * LineFeeder}, with the same
     *
     * @param msg is the normal Exception message
     * @param quoted Will this next line be taken as literal text?  If so,
     *               then it should not be trimmed or indented.  'quoted' is
     *               true between double quotes, or between quasi-quotes when
     *               not inside a $ or @ hole.
     * @param indent The suggested indentation level for the next line,
     *               unless the next line begins with closer.
     * @param closer The character that would close the most recent unclosed
     *               openner.
     * @param closeIndent The suggested indentation level for the next line
     *                    if it does begin (after trimming) with closer.
     */
    public NeedMoreException(String msg,
                             boolean quoted,
                             int indent,
                             char closer,
                             int closeIndent) {
        super(msg);
        myIndent = indent;
    }

    /**
     *
     */
    public boolean isQuoted() {
        return myQuoted;
    }

    /**
     *
     */
    public int indent() {
        return myIndent;
    }

    /**
     *
     */
    public char getCloser() {
        return myCloser;
    }

    /**
     *
     */
    public int getCloseIndent() {
        return closeIndent;
    }
}



1.1                  e/src/jsrc/org/quasiliteral/syntax/SyntaxException.java

Index: SyntaxException.java
===================================================================
package org.quasiliteral.syntax;

/*
The contents of this file are subject to the Electric Communities E Open
Source Code License Version 1.0 (the "License"); you may not use this file
except in compliance with the License. You may obtain a copy of the License
at http://www.communities.com/EL/.

Software distributed under the License is distributed on an "AS IS" basis,
WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for
the specific language governing rights and limitations under the License.

The Original Code is the Distributed E Language Implementation, released
July 20, 1998.

The Initial Developer of the Original Code is Electric Communities.
Copyright (C) 1998 Electric Communities. All Rights Reserved.

Contributor(s): ______________________________________.
*/

import org.erights.e.develop.format.StringHelper;
import org.erights.e.elib.base.SourceSpan;
import org.erights.e.elib.eio.EPrintable;
import org.erights.e.elib.eio.TextWriter;
import org.erights.e.elib.tables.Twine;

import java.io.IOException;

/**
 * Thrown if there's a grammatical error in the input.
 *
 * @author <a href="mailto:markm@erights.org">Mark S. Miller</a>
 */
public class SyntaxException
  extends RuntimeException implements EPrintable {

    private Twine myOptLine;

    private int myStart;

    private int myBound;

    /**
     *
     */
    public SyntaxException(String msg,
                           Twine optLine,
                           int start,
                           int bound) {
        super(msg);
        myOptLine = optLine;
        myStart = start;
        myBound = bound;
    }

    /**
     *
     */
    public Twine optLine() {
        return myOptLine;
    }

    /**
     *
     */
    public int getStart() {
        return myStart;
    }

    /**
     *
     */
    public int getBound() {
        return myBound;
    }

    /**
     *
     */
    public Twine optDamage() {
        if (null == myOptLine) {
            return null;
        } else {
            return (Twine)myOptLine.run(myStart, myBound);
        }
    }

    static private final String ErrPrefix = "syntax error: ";

    /** Same number of spaces as in the ErrPrefix */
    static private final String ErrIndent =
      StringHelper.multiply(" ", ErrPrefix.length());

    /**
     * Prints as "syntax error: " followed by an optional message, and then
     * an optional indication of the location of the error.
     */
    public void printOn(TextWriter out) throws IOException {
        out.print(ErrPrefix);
        String msg = getMessage();
        if (!msg.equals("syntax error")) {
            out.indent(ErrIndent).print(msg);
        }
        if (null != myOptLine) {
            out = out.indent("  ");
            out.lnPrint(myOptLine.replaceAll("\t", " "));
            if (!myOptLine.endsWith("\n")) {
                out.println();
            }
            out.print(StringHelper.multiply(" ", myStart));
            out.print(StringHelper.multiply("^", myBound - myStart));
            Twine section = (Twine)myOptLine.run(myStart, myBound);
            SourceSpan optSpan = section.optSourceSpan();
            if (null != optSpan) {
                out.lnPrint(optSpan);
            }
        }
    }
}




1.1                  e/src/jsrc/org/quasiliteral/syntax/TwineFeeder.java

Index: TwineFeeder.java
===================================================================
package org.quasiliteral.syntax;

/*
The contents of this file are subject to the Electric Communities E Open
Source Code License Version 1.0 (the "License"); you may not use this file
except in compliance with the License. You may obtain a copy of the License
at http://www.communities.com/EL/.

Software distributed under the License is distributed on an "AS IS" basis,
WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for
the specific language governing rights and limitations under the License.

The Original Code is the Distributed E Language Implementation, released
July 20, 1998.

The Initial Developer of the Original Code is Electric Communities.
Copyright (C) 1998 Electric Communities. All Rights Reserved.

Contributor(s): ______________________________________.
*/

import org.erights.e.elib.tables.Twine;

/**
 * For feeding in one line of Twine at a time taken from a dynamically
 * provided Twine source.
 *
 * @author <a href="mailto:markm@erights.org">Mark S. Miller</a>
 */
public class TwineFeeder implements LineFeeder {

    private Twine mySource;

    private int myPos;

    /**
     *
     */
    public TwineFeeder(Twine sourceCode) {
        mySource = sourceCode;
        myPos = 0;
    }

    /**
     *
     */
    public Twine optNextLine(boolean quoted,
                             int indent,
                             char closer,
                             int closeIndent) {
        int len = mySource.size();
        if (myPos >= len) {
            return null;
        }
        int i = mySource.indexOf("\n", myPos);
        if (-1 == i) {
            Twine result = (Twine)mySource.run(myPos, len);
            myPos = len;
            return result;
        }
        Twine result = (Twine)mySource.run(myPos, i + 1);
        myPos = i + 1;
        return result;
    }
}



1.8       +112 -602  e/src/jsrc/org/quasiliteral/term/TermLexer.java

Index: TermLexer.java
===================================================================
RCS file: /cvs/e/src/jsrc/org/quasiliteral/term/TermLexer.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- TermLexer.java	2001/11/27 07:27:54	1.7
+++ TermLexer.java	2001/12/02 18:42:02	1.8
@@ -1,310 +1,131 @@
 package org.quasiliteral.term;
 
+/*
+The contents of this file are subject to the Electric Communities E Open
+Source Code License Version 1.0 (the "License"); you may not use this file
+except in compliance with the License. You may obtain a copy of the License
+at http://www.communities.com/EL/.
+
+Software distributed under the License is distributed on an "AS IS" basis,
+WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for
+the specific language governing rights and limitations under the License.
+
+The Original Code is the Distributed E Language Implementation, released
+July 20, 1998.
+
+The Initial Developer of the Original Code is Electric Communities.
+Copyright (C) 1998 Electric Communities. All Rights Reserved.
+
+Contributor(s): ______________________________________.
+*/
+
 import org.erights.e.develop.exception.PrintStreamWriter;
-import org.erights.e.develop.exception.ThrowableSugar;
-import org.erights.e.elang.syntax.FileFeeder;
-import org.erights.e.elang.syntax.Indenter;
-import org.erights.e.elang.syntax.LineFeeder;
-import org.erights.e.elang.syntax.SyntaxException;
-import org.erights.e.elang.syntax.TwineFeeder;
 import org.erights.e.elib.eio.TextWriter;
-import org.erights.e.elib.tables.Twine;
 import org.erights.e.elib.tables.EmptyTwine;
+import org.erights.e.elib.tables.Twine;
+import org.quasiliteral.astro.AstroSchema;
 import org.quasiliteral.astro.AstroToken;
+import org.quasiliteral.astro.AstroTag;
+import org.quasiliteral.syntax.BaseLexer;
+import org.quasiliteral.syntax.FileFeeder;
+import org.quasiliteral.syntax.LineFeeder;
+import org.quasiliteral.syntax.SyntaxException;
+import org.quasiliteral.syntax.TwineFeeder;
 
 import java.io.BufferedReader;
 import java.io.FileReader;
 import java.io.IOException;
-import java.math.BigInteger;
 
 /**
- * Breaks textually input into a stream of tokens according to the Term
+ * Breaks textually input into a stream of tokens according to the E
  * language's defined grammar.
- * <p>
- * XXX To be replaced with a lexer generated by Antlr
  *
  * @author <a href="mailto:markm@erights.org">Mark S. Miller</a>
  */
-public class TermLexer {
+public class TermLexer extends BaseLexer {
 
     /**
      *
-     */
-    static public final int EOFCHAR = -1;
-
-    /** contains all lines after the current line */
-    private LineFeeder myInput;
-
-    /** the current line, or null at end-of-file */
-    public Twine myLTwine = null;
-
-    /** the string part, but as an array for speed */
-    public char[] myLData = null;
-
-    /** position in current line of candidate character */
-    private int myPos;
-
-    /** the candidate character, or EOFCHAR for end-of-file. */
-    private int myChar;
-
-    /**
-     * Where on the current line does the current token start?  If the token
-     * starts before the current line, or if there is no current token, this
-     * is -1.
-     */
-    private int myOptStartPos = -1;
-
-    /**
-     * Accumulates all text of the current token from lines before the
-     * current line, or null if no current token or if the current
-     * token starts on the current line.  The EOL token itself is not
-     * considered to be a line spanning token.
-     */
-    private Twine myOptStartText = null;
-
-    /**
-     * Keeps track of indentation level
-     */
-    private Indenter myIndenter;
-
-    /**
-     * Should the next line get extra indentation as a continuation line?
      */
-    private boolean myContinueFlag;
+    static private final String QUASI_ENDER = "$@`";
 
     /**
      *
      */
-    private boolean myQuasiFlag;
+    public TermLexer(LineFeeder input,
+                     boolean partialFlag,
+                     boolean noTabsFlag)
+      throws IOException {
+        this(input, partialFlag, noTabsFlag, TermParser.DEFAULT_SCHEMA);
+    }
 
     /**
-     * @param input Where lines come from
-     * @param quasiFlag Should doubled @ and $ be collapsed to singles?
+     *
      */
-    public TermLexer(LineFeeder input, boolean quasiFlag)
+    public TermLexer(LineFeeder input,
+                     boolean partialFlag,
+                     boolean noTabsFlag,
+                     AstroSchema schema)
       throws IOException {
-
-        myInput = input;
-        myPos = -1;
-        myLTwine = myInput.optNextLine(false, 0, 'x', 0);
-        if (null == myLTwine) {
-            myLData = null;
-        } else {
-            myLData = myLTwine.bare().toCharArray();
-        }
-        nextChar();
-        myIndenter = new Indenter();
-        myContinueFlag = false;
-        myQuasiFlag = quasiFlag;
+        super(input, partialFlag, noTabsFlag, schema);
     }
 
     /**
      * @param sourceCode The source code itself
      * @param quasiFlag Should doubled @ and $ be collapsed to singles?
+     * @param noTabsFlag Should tabs be rejected as valid whitespace?
+     *                   Assumed to correspond to the e.enable.notabs
+     *                   property.
      */
-    static public TermLexer make(Twine sourceCode, boolean quasiFlag) {
+    static public TermLexer make(Twine sourceCode,
+                                 boolean noTabsFlag)
+      throws IOException {
         LineFeeder lineFeeder = new TwineFeeder(sourceCode);
-        try {
-            return new TermLexer(lineFeeder, quasiFlag);
-        } catch (IOException ioe) {
-            throw ThrowableSugar.backtrace(ioe, "Parsing a string?");
-        }
-    }
-
-    /**
-     * Skip to the end of this line, so that the next character read will be
-     * from the next line, forget any token we may have been in the midst
-     * of, and reset our indentation tracker.
-     */
-    private void reset() {
-        if (null != myLTwine) {
-            //A cheat
-            myPos = myLData.length;
-            myChar = '\n';
-        }
-        myOptStartPos = -1;
-        myOptStartText = null;
-        myIndenter = new Indenter();
-        myContinueFlag = false;
-    }
-
-    /**
-     *
-     */
-    private void nextLine() throws IOException {
-        if (myLTwine == null) {
-            myChar = EOFCHAR;
-            return;
-        }
-        if (-1 == myOptStartPos) {
-            if (null == myOptStartText) {
-                //no current token, do nothing
-            } else {
-                //current token already started
-                myOptStartText = (Twine)myOptStartText.add(myLTwine);
-            }
-        } else {
-            //current token started on this line at myOptStartPos
-            myOptStartText = (Twine)myLTwine.run(myOptStartPos,
-                                                 myLTwine.size());
-            myOptStartPos = -1;
-        }
-        myPos = -1;
-
-        char closer = myIndenter.getCloser();
-        int indent = myIndenter.getIndent();
-        if (myContinueFlag) {
-            indent += 2;
-        }
-        myLTwine =
-          myInput.optNextLine(('"' == closer || '`' == closer),
-                              indent,
-                              closer,
-                              myIndenter.getCloseIndent());
-
-        if (null == myLTwine) {
-            //don't clear myContinueFlag on end-of-file
-            myLData = null;
-        } else {
-            myContinueFlag = false;
-            myLData = myLTwine.bare().toCharArray();
-        }
-        myChar = '\n';
+        return new TermLexer(lineFeeder, false, noTabsFlag);
     }
 
     /**
      *
      */
-    private void nextChar() throws IOException {
-        while (true) {
-            if (null == myLTwine) {
-                myChar = EOFCHAR;
-                return;
-            }
-            myPos++;
-            int len = myLData.length;
-            if (myPos < len) {
-                myChar = myLData[myPos];
-                return;
-            } else {
-                nextLine();
-            }
-        }
+    protected boolean isContinuer(int tokenType) {
+        return false;
     }
 
     /**
      *
      */
-    public AstroToken nextToken() throws IOException, SyntaxException {
-        AstroToken result;
-        try {
-            result = getNextToken();
-        } finally {
-            myOptStartPos = -1;
-            myOptStartText = null;
-        }
-        if (TermParser.isContinuer(result.getType())) {
-            return continuer(result);
-        } else {
-            return result;
-        }
-    }
-
-    /**
-     * Separated out for use by '>'
-     */
-    private AstroToken continuer(AstroToken result) throws IOException {
-        if (isWhite(myPos, myLData.length)) {
-            myContinueFlag = true;
-            skipLine();
-        }
-        return result;
-    }
-
-    /**
-     *
-     */
-    /*package*/ void syntaxError(String msg)
-      throws SyntaxException {
-        int start = myOptStartPos;
-        if (-1 == start) {
-            start = myPos - 1;
-        }
-        start = Math.max(Math.min(start, myPos - 1), 0);
-        int bound = Math.max(myPos, start + 1);
-        SyntaxException sex = new SyntaxException(msg,
-                                                  myLTwine,
-                                                  start,
-                                                  bound);
-        reset();
-        throw sex;
-    }
-
-    /**
-     *
-     */
-    private boolean eatDigit(int radix) throws IOException {
-        if (Character.digit((char)myChar, radix) != -1 || myChar == '_') {
+    protected AstroToken getNextToken() throws IOException, SyntaxException {
+        if (myDelayedNextChar) {
             nextChar();
-            return true;
-        } else {
-            return false;
-        }
-    }
-
-    /**
-     *
-     */
-    private void skipWhiteSpace() throws IOException {
-        while (true) {
-            if (myChar == EOFCHAR) {
-                return;
-            }
-            if (Character.isWhitespace((char)myChar)) {
-                nextChar();
-            } else {
-                return;
-            }
+            myDelayedNextChar = false;
         }
-    }
 
-    /**
-     * Are all the characters on the current line from start inclusive to
-     * bound exclusive whitespace characters?
-     */
-    private boolean isWhite(int start, int bound) {
-        for (int i = start; i < bound; i++) {
-            if (!Character.isWhitespace(myLData[i])) {
-                return false;
-            }
-        }
-        return true;
-    }
-
-    /**
-     *
-     */
-    private AstroToken getNextToken() throws IOException, SyntaxException {
         skipWhiteSpace();
         startToken();
 
         switch (myChar) {
             case ',':
-            case ':':
-            case '$':
-            case '@':
+            case '|':
+            case '.':
+            case '^':
             case '?':
             case '+':
             case '*':
+            case '$':
+            case '@':
                 {
                     char c = (char)myChar;
                     nextChar();
-                    return new AstroToken(c, endToken());
+                    return leafTag(c, endToken());
                 }
             case EOFCHAR:
+                {
+                    return leafTag(TermParser.EOFTOK, EmptyTwine.THE_ONE);
+                }
+            case '\n':
                 {
-                    return new AstroToken(TermParser.EOFTOK,
-                                          EmptyTwine.THE_ONE);
+                    myDelayedNextChar = true;
+                    return leafTag(TermParser.EOL, endToken());
                 }
             case '(':
                 {
@@ -322,12 +143,26 @@
                 {
                     return closeBracket();
                 }
+            case '/':
+                {
+                    nextChar();
+                    if (myChar == '/') {
+                        // Skip comment to end of line
+                        skipLine();
+                        return leafTag(TermParser.EOL, endToken());
+                    } else if (myChar == '*') {
+                        nextChar();
+                        syntaxError("'/*..*/' comments are reserved. " +
+                                    "Use '#' or '//' on each line instead");
+                    }
+                    syntaxError("No lone '/' in Term syntax");
+                    return null; //keep compiler happy
+                }
             case '#':
                 {
                     // Skip comment to end of line (as in "//" case above).
                     skipLine();
-                    stopToken();
-                    return getNextToken();
+                    return leafTag(TermParser.EOL, endToken());
                 }
             case '\\':
                 {
@@ -336,6 +171,21 @@
                         syntaxError("\\u... not yet implemented");
                         return null; //keep compiler happy
                     }
+                    //an escaped newline is insensitive to trailing
+                    //whitespace, since that's invisible anyway.
+                    skipWhiteSpace();
+                    if (myChar == '\n') {
+                        myContinueFlag = true;
+                        skipLine();
+                        stopToken();
+                        AstroToken result = getNextToken();
+                        if (result.getType() == TermParser.EOFTOK) {
+                            needMore("continued line");
+                            return null; //make compiler happy
+                        } else {
+                            return result;
+                        }
+                    }
                     syntaxError("unrecognized escape");
                     return null; //keep compiler happy
                 }
@@ -359,14 +209,14 @@
             case '9':
                 {
                     return numberLiteral();
-
                 }
             default:
                 {
                     if (isIdentifierStart((char)myChar)) {
                         return identifier();
                     } else {
-                        syntaxError("unrecognized character: '" + (char)myChar +
+                        syntaxError("unrecognized character: '" +
+                                    (char)myChar +
                                     "' code: " + (int)myChar);
                         return null; //keep compiler happy
                     }
@@ -375,365 +225,19 @@
     }
 
     /**
-     *
-     */
-    private AstroToken openBracket(char closer) throws IOException {
-        int tokenType = myChar;
-        nextChar();
-        Twine openner = endToken();
-        return openBracket(tokenType, openner, closer);
-    }
-
-    /**
-     *
-     */
-    private AstroToken openBracket(int tokenType, Twine openner, char closer)
-      throws IOException {
-        if (isWhite(myPos, myLData.length)) {
-            myIndenter.nest(openner, closer);
-        } else {
-            //Indent the next line to right after the open.
-            myIndenter.push(openner, closer, myPos);
-        }
-        return new AstroToken(tokenType, openner);
-    }
-
-    /**
-     *
-     */
-    private AstroToken closeBracket() throws IOException {
-        char closerChar = (char)myChar;
-        nextChar();
-        Twine closer = endToken();
-        //on mismatched close, throws SyntaxError at openner
-        //on unmatched close, throws Syntax error at closer
-        myIndenter.pop(closerChar, closer);
-        return new AstroToken(closerChar, closer);
-    }
-
-    /**
-     *
-     */
-    private char charConstant() throws IOException, SyntaxException {
-        switch (myChar) {
-            case '\\':
-                {
-                    nextChar();
-                    switch (myChar) {
-                        case 'b':
-                            return '\b';
-                        case 't':
-                            return '\t';
-                        case 'n':
-                            return '\n';
-                        case 'f':
-                            return '\f';
-                        case 'r':
-                            return '\r';
-                        case '"':
-                            return '"';
-                        case '\'':
-                            return '\'';
-                        case '\\':
-                            return '\\';
-                        case '\n':
-                            {
-                                //XXX need to move into stringLiteral only
-                                //XXX bug: must be accepted at end of string
-                                nextChar();
-                                return charConstant();
-                            }
-                        case EOFCHAR:
-                            {
-                                syntaxError("End of file in middle of literal");
-                            }
-                        case 'u':
-                            {
-                                syntaxError
-                                  ("XXX escaped uchar codes not yet implemented");
-                            }
-                        default:
-                            {
-                                if (Character.isDigit((char)myChar)) {
-                                    syntaxError
-                                      ("XXX escaped char codes not yet implemented");
-                                } else {
-                                    syntaxError("Unrecognized escaped character");
-                                }
-                            }
-                    }
-                }
-            case '$':
-            case '@':
-            case '`':
-                {
-                    char c = (char)myChar;
-                    if (myQuasiFlag) {
-                        nextChar();
-                        if (c == myChar) {
-                            //collapse double to single
-                            return c;
-                        } else {
-                            //require double
-                            syntaxError("Expected: " + c + c);
-                        }
-                    } else {
-                        //treat as a normal character
-                        return c;
-                    }
-                }
-            case EOFCHAR:
-                {
-                    syntaxError("End of file in middle of literal");
-                }
-            default:
-                {
-                    return (char)myChar;
-                }
-        }
-    }
-
-    /**
-     *
-     */
-    private AstroToken charLiteral() throws IOException, SyntaxException {
-        nextChar();
-        char value = charConstant();
-        nextChar();
-        if (myChar != '\'') {
-            syntaxError("char constant must end in \"'\"");
-        }
-        nextChar();
-        return new AstroToken(TermParser.LiteralChar,
-                              endToken(),
-                              new Character(value));
-    }
-
-    /**
      * Called with myChar as the first character of the identifier.
      */
-    private AstroToken identifier() throws IOException, SyntaxException {
+    protected AstroToken identifier() throws IOException, SyntaxException {
         do {
             nextChar();
         } while (myChar != EOFCHAR && isIdentifierPart((char)myChar));
         Twine source = endToken();
-        return new AstroToken(TermParser.ID, source, source.bare());
-    }
-
-    /** pretty self explanatory */
-    public boolean isEndOfFile() {
-        return null == myLTwine;
-    }
-
-    /**
-     * The first character of an E identifier may be anything accepted
-     * as the first character of a Java identifier except '$'.  I.e.,
-     * a letter or '_'.
-     *
-     * @see java.lang.Character#isJavaIdentifierStart
-     */
-    static public boolean isIdentifierStart(char ch) {
-        return Character.isJavaIdentifierStart(ch) && ch != '$';
-    }
-
-    /**
-     * A non-first character of an E identifier may be anything
-     * accepted as a non-first character of a Java identifier except
-     * '$'. The ascii subset consists of letters, digits, and '_'.
-     * See Character.isJavaIdentifierPart() for the full spec.
-     *
-     * @see java.lang.Character#isJavaIdentifierPart
-     */
-    static public boolean isIdentifierPart(char ch) {
-        return Character.isJavaIdentifierPart(ch) && ch != '$';
-    }
-
-    /**
-     * Is 'str' a legal E identifier?
-     */
-    static public boolean isIdentifier(String str) {
-        int len = str.length();
-        if (len <= 0) {
-            return false;
-        }
-        if (!isIdentifierStart(str.charAt(0))) {
-            return false;
-        }
-        for (int i = 1; i < len; i++) {
-            if (!isIdentifierPart(str.charAt(i))) {
-                return false;
-            }
-        }
-        return true;
-    }
-
-    /**
-     *
-     */
-    private AstroToken numberLiteral()
-      throws IOException, SyntaxException {
-        // Now handles floating point numbers as well as integers
-        boolean floating = false;
-        int radix = 10;
-        if (myChar == '0') {
-            radix = 8;
-            nextChar();
-            if (myChar == 'x' || myChar == 'X') {
-                radix = 16;
-                nextChar();
-            }
-        }
-        if (radix == 16) {
-            while (eatDigit(16)) {
-            }
-        } else {
-            //even if radix == 8, we may instead have a floating point literal
-            while (eatDigit(10)) {
-            }
-            // If we have a decimal point go for the fractional part
-            if (myChar == '.' && !peekChar('.')) {
-                nextChar();
-                floating = true;
-                while (eatDigit(10)) {
-                }
-            }
-
-            if ((myChar == 'E') || (myChar == 'e')) {
-                nextChar();
-                floating = true;
-                if (myChar == '-') {
-                    nextChar();
-                }
-                while (eatDigit(10)) {
-                }
-            }
-        }
-        Twine tok = endToken();
-        String str = tok.replaceAll("_", "").bare();
-        if (floating) {
-            return new AstroToken(TermParser.LiteralFloat64,
-                                  tok,
-                                  Double.valueOf(str));
-        } else {
-            if (radix == 16) {
-                //remove the leading "0x" to make BigInteger happy
-                str = str.substring(2);
-            }
-            return new AstroToken(TermParser.LiteralInteger,
-                                  tok,
-                                  new BigInteger(str, radix));
-        }
-    }
-
-    /**
-     * XXX Get rid of peekChar/0 or make it work
-     */
-    private char peekChar() {
-        if (myChar == EOFCHAR || myChar == '\n') {
-            throw new Error("internal: can't peek here");
-        }
-        int last = myLData.length - 1;
-
-        if (myPos < last) {
-            return myLData[myPos + 1];
-        } else {
-            throw new Error("internal: (XXX bug) peek past end");
-        }
+        //The term grammar has no keywords, so all apparent identifiers are
+        //actual identifiers
+        return composite(TermParser.ID, source.bare(), source);
     }
 
     /**
-     *
-     */
-    private boolean peekChar(char c) {
-        if (myChar == EOFCHAR || myChar == '\n') {
-            throw new Error("internal: can't peek here");
-        }
-        int last = myLData.length - 1;
-
-        if (myPos < last) {
-            return c == myLData[myPos + 1];
-        } else {
-            return false;
-        }
-    }
-
-    /**
-     * Skip to the rest of this line.
-     */
-    private void skipLine() throws IOException {
-        if (null != myLTwine) {
-            myPos = myLData.length - 1;
-            myChar = myLData[myPos];
-        }
-        nextChar();
-    }
-
-    /**
-     *
-     */
-    private void startToken() {
-        if (-1 != myOptStartPos || null != myOptStartText) {
-            throw new Error("internal: token already started");
-        }
-        myOptStartPos = myPos;
-    }
-
-    /**
-     * Cancels a started token
-     */
-    private void stopToken() {
-        myOptStartPos = -1;
-        myOptStartText = null;
-    }
-
-    /**
-     *
-     */
-    private Twine endToken() {
-        Twine result;
-        int pos = myPos;
-        if (-1 == myOptStartPos) {
-            if (null == myOptStartText) {
-                throw new Error("internal: no current token");
-            } else {
-                //started on previous line
-                result = myOptStartText;
-                if (null != myLTwine) {
-                    result = (Twine)result.add(myLTwine.run(0, pos));
-                }
-            }
-        } else {
-            //starts on this line
-            result = (Twine)myLTwine.run(myOptStartPos, pos);
-        }
-        stopToken();
-        return result;
-    }
-
-    /**
-     *
-     */
-    private AstroToken stringLiteral() throws IOException, SyntaxException {
-        nextChar();
-        Twine openner = (Twine)myLTwine.run(myOptStartPos, myPos);
-        myIndenter.push(openner, '"', 0);
-        StringBuffer value = new StringBuffer();
-        while (myChar != '"') {
-            if (myChar == EOFCHAR) {
-                syntaxError("File ends inside string literal");
-            }
-            value.append(charConstant());
-            nextChar();
-        }
-        nextChar();
-        Twine closer = endToken();
-        myIndenter.pop('"', closer);
-        return new AstroToken(TermParser.LiteralString,
-                              closer,
-                              value.toString());
-    }
-
-    /**
      * Just for testing.  Reads an input file and prints one token per line
      * to stdout.
      */
@@ -751,16 +255,22 @@
             ins = new BufferedReader(new FileReader(args[0]));
         } else {
             throw new RuntimeException
-              ("usage: java org.quasiliteral.term.TermLexer file");
+              ("usage: java org.erights.e.elang.syntax.ELexer file");
         }
         LineFeeder lr = new FileFeeder(url, ins, stdout);
-        TermLexer lex = new TermLexer(lr, false);
+        TermLexer lex = new TermLexer(lr, false, false);
         while (true) {
             try {
                 AstroToken t;
                 do {
                     t = lex.nextToken();
-                    stdout.println(t.asFunctor(TermParser.getTokenNames()));
+                    //XXX should print t as a Functor.
+                    stdout.println(t);
+                    if (t.getType() == TermParser.EOL) {
+                        stdout.print("stack: ",
+                                     lex.myIndenter.toString(),
+                                     "\n");
+                    }
                 } while (t.getType() != TermParser.EOFTOK);
                 return;
             } catch (SyntaxException sex) {



1.9       +60 -45    e/src/jsrc/org/quasiliteral/term/TermParser.java

Index: TermParser.java
===================================================================
RCS file: /cvs/e/src/jsrc/org/quasiliteral/term/TermParser.java,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -r1.8 -r1.9
--- TermParser.java	2001/12/01 03:44:02	1.8
+++ TermParser.java	2001/12/02 18:42:02	1.9
@@ -11,14 +11,16 @@
 //#line 7 "term.y"
 package org.quasiliteral.term;
 
-import org.erights.e.elang.syntax.SyntaxException;
+
+import org.quasiliteral.astro.AstroSchema;
+import org.quasiliteral.astro.AstroToken;
+import org.quasiliteral.astro.BaseSchema;
+import org.quasiliteral.syntax.SyntaxException;
 import org.erights.e.elib.tables.ConstList;
 import org.erights.e.elib.tables.Twine;
-import org.quasiliteral.astro.AstroToken;
-import org.quasiliteral.astro.TreeBuilder;
 
 import java.io.IOException;
-//#line 19 "TermParser.java"
+//#line 22 "TermParser.java"
 
 
 
@@ -154,6 +156,7 @@
 public final static short LiteralInteger=259;
 public final static short LiteralFloat64=260;
 public final static short LiteralString=261;
+public final static short EOL=262;
 public final static short YYERRCODE=256;
 final static short yylhs[] = {                           -1,
     0,    1,    1,    1,    1,    1,    3,    3,    5,    5,
@@ -244,7 +247,7 @@
   257,  258,  259,  260,  261,  257,  258,  259,  260,  261,
 };
 final static short YYFINAL=8;
-final static short YYMAXTOKEN=261;
+final static short YYMAXTOKEN=262;
 final static String yyname[] = {
 "end-of-file",null,null,null,null,null,null,null,null,null,null,null,null,null,
 null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
@@ -263,7 +266,7 @@
 null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
 null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
 null,null,null,null,null,null,null,null,null,"ID","LiteralChar",
-"LiteralInteger","LiteralFloat64","LiteralString",
+"LiteralInteger","LiteralFloat64","LiteralString","EOL",
 };
 final static String yyrule[] = {
 "$accept : start",
@@ -297,8 +300,9 @@
 "functorHole : '@' '{' LiteralInteger '}'",
 };
 
-//#line 127 "term.y"
+//#line 133 "term.y"
 
+
 /**
  * contains all the tokens after yylval
  */
@@ -307,7 +311,7 @@
 /**
  *
  */
-private TreeBuilder b;
+private TermSchema b;
 
 /**
  *
@@ -317,23 +321,23 @@
 /**
  *
  */
-public TermParser(TermLexer lexer, TreeBuilder builder) {
+public TermParser(TermLexer lexer, TermSchema builder) {
     myLexer = lexer;
     b = builder;
     myOptResult = null;
 }
 
 /**
- * builder defaults to SimpleTermBuilder
+ * builder defaults to the SimpleTermSchema instance
  */
 static public Term run(Twine source) {
-    return (Term)run(source, SimpleTermBuilder.THE_ONE);
+    return (Term)run(source, SimpleTermSchema.THE_ONE);
 }
 
 /**
  *
  */
-static public Object run(Twine source, TreeBuilder builder) {
+static public Object run(Twine source, TermSchema builder) {
     TermLexer lexer = TermLexer.make(source, builder.doesQuasis());
     TermParser parser = new TermParser(lexer, builder);
     return parser.parse();
@@ -350,7 +354,7 @@
     }
     return null; //keep compiler happy
 }
-
+    
 
 /**
  *
@@ -404,15 +408,26 @@
      */
 
     TheTokens[EOFTOK]           = "EndOfFile";
+
+    TheTokens[ID]               = "ID";
+    
+    TheTokens[LiteralInteger]   = "LiteralInteger";
+    TheTokens[LiteralFloat64]   = "LiteralFloat64";
+    TheTokens[LiteralChar]      = "LiteralChar";
+    TheTokens[LiteralString]    = "LiteralString";
+
+    /* Eaten as whitespace at a higher level */
+    TheTokens[EOL]              = "EOL";
+
 }
 
 /**
  *
  */
-static public ConstList getTokenNames() {
-    return ConstList.fromArray(TheTokens);
-}
-//#line 363 "TermParser.java"
+static public final AstroSchema DEFAULT_SCHEMA =
+  new BaseSchema(ConstList.fromArray(TheTokens));
+
+//#line 379 "TermParser.java"
 //###############################################################
 // method: yylexdebug : check lexer state
 //###############################################################
@@ -448,7 +463,7 @@
   while (true) //until parsing is done, either correctly, or w/error
     {
     doaction=true;
-    if (yydebug) debug("loop");
+    if (yydebug) debug("loop"); 
     //#### NEXT ACTION (from reduction table)
     for (yyn=yydefred[yystate];yyn==0;yyn=yydefred[yystate])
       {
@@ -559,110 +574,110 @@
       {
 //########## USER-SUPPLIED ACTIONS ##########
 case 1:
-//#line 65 "term.y"
+//#line 70 "term.y"
 { myOptResult = val_peek(0); }
 break;
 case 2:
-//#line 69 "term.y"
+//#line 74 "term.y"
 { yyval = b.term(val_peek(0), b.argList()); }
 break;
 case 3:
-//#line 70 "term.y"
+//#line 75 "term.y"
 { yyval = b.term(val_peek(3), val_peek(1)); }
 break;
 case 4:
-//#line 71 "term.y"
+//#line 76 "term.y"
 { yyval = b.term(val_peek(3), val_peek(1)); }
 break;
 case 5:
-//#line 73 "term.y"
+//#line 78 "term.y"
 { yyval = b.termHole(null, val_peek(0)); }
 break;
 case 6:
-//#line 74 "term.y"
+//#line 79 "term.y"
 { yyval = b.termHole((AstroToken)val_peek(1), val_peek(0));}
 break;
 case 7:
-//#line 78 "term.y"
+//#line 83 "term.y"
 { yyval = b.argList(); }
 break;
 case 9:
-//#line 83 "term.y"
+//#line 88 "term.y"
 { yyval = b.argList(val_peek(0)); }
 break;
 case 10:
-//#line 84 "term.y"
+//#line 89 "term.y"
 { yyval = b.argList(val_peek(2), val_peek(0)); }
 break;
 case 12:
-//#line 89 "term.y"
+//#line 94 "term.y"
 { yyval = b.alt(val_peek(2), val_peek(0)); }
 break;
 case 13:
-//#line 96 "term.y"
+//#line 101 "term.y"
 { yyval = b.seq(  val_peek(0), "."); }
 break;
 case 14:
-//#line 97 "term.y"
+//#line 102 "term.y"
 { yyval = b.seq(  val_peek(1), (String)val_peek(0)); }
 break;
 case 15:
-//#line 98 "term.y"
+//#line 103 "term.y"
 { yyval = b.seq(null, (String)val_peek(0)); }
 break;
 case 16:
-//#line 99 "term.y"
+//#line 104 "term.y"
 { yyval = b.seq(null, "."); }
 break;
 case 17:
-//#line 100 "term.y"
+//#line 105 "term.y"
 { yyval = b.argGroup(val_peek(2), (String)val_peek(0)); }
 break;
 case 18:
-//#line 101 "term.y"
+//#line 106 "term.y"
 { %% = b.unpack(val_peek(0)); }
 break;
 case 19:
-//#line 105 "term.y"
+//#line 110 "term.y"
 { yyval = "?"; }
 break;
 case 20:
-//#line 106 "term.y"
+//#line 111 "term.y"
 { yyval = "+"; }
 break;
 case 21:
-//#line 107 "term.y"
+//#line 112 "term.y"
 { yyval = "*"; }
 break;
 case 22:
-//#line 111 "term.y"
+//#line 116 "term.y"
 { yyval = b.tag((AstroToken)val_peek(0)); }
 break;
 case 23:
-//#line 112 "term.y"
+//#line 117 "term.y"
 { yyval = b.litChar((AstroToken)val_peek(0)); }
 break;
 case 24:
-//#line 113 "term.y"
+//#line 118 "term.y"
 { yyval = b.litInteger((AstroToken)val_peek(0)); }
 break;
 case 25:
-//#line 114 "term.y"
+//#line 119 "term.y"
 { yyval = b.litFloat64((AstroToken)val_peek(0)); }
 break;
 case 26:
-//#line 115 "term.y"
+//#line 120 "term.y"
 { yyval = b.litString((AstroToken)val_peek(0)); }
 break;
 case 27:
-//#line 122 "term.y"
+//#line 127 "term.y"
 { yyval = b.dollarHole((AstroToken)val_peek(1)); }
 break;
 case 28:
-//#line 123 "term.y"
+//#line 128 "term.y"
 { yyval = b.atHole((AstroToken)val_peek(1)); }
 break;
-//#line 610 "TermParser.java"
+//#line 626 "TermParser.java"
 //########## END OF USER-SUPPLIED ACTIONS ##########
     }//switch
     //#### Now let's reduce... ####



1.8       +27 -11    e/src/jsrc/org/quasiliteral/term/term.y

Index: term.y
===================================================================
RCS file: /cvs/e/src/jsrc/org/quasiliteral/term/term.y,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- term.y	2001/11/27 07:27:54	1.7
+++ term.y	2001/12/02 18:42:02	1.8
@@ -6,10 +6,13 @@
 %{
 package org.quasiliteral.term;
 
-import org.erights.e.elang.syntax.SyntaxException;
+
+import org.quasiliteral.astro.AstroSchema;
+import org.quasiliteral.astro.AstroToken;
+import org.quasiliteral.astro.BaseSchema;
+import org.quasiliteral.syntax.SyntaxException;
 import org.erights.e.elib.tables.ConstList;
 import org.erights.e.elib.tables.Twine;
-import org.quasiliteral.astro.AstroToken;
 
 import java.io.IOException;
 %}
@@ -22,12 +25,14 @@
 %token LiteralFloat64   //like Java & E: IEEE double precision
 %token LiteralString    //like Java & E: double quoted
 
+%token EOL              //eaten as whitespace at a higher level
+
 %%
 
 /**
  * The starting production represents a single Term.
  * <p>
- * To understand what these productions mean, see {@link TermBuilder}.
+ * To understand what these productions mean, see {@link TermSchema}.
  * <p>
  * It's worth noting that the pure literal (or non-quasi) subset of
  * this grammar is simply:<pre>
@@ -135,7 +140,7 @@
 /**
  *
  */
-private TermBuilder b;
+private TermSchema b;
 
 /**
  *
@@ -145,23 +150,23 @@
 /**
  *
  */
-public TermParser(TermLexer lexer, TermBuilder builder) {
+public TermParser(TermLexer lexer, TermSchema builder) {
     myLexer = lexer;
     b = builder;
     myOptResult = null;
 }
 
 /**
- * builder defaults to SimpleTermBuilder
+ * builder defaults to the SimpleTermSchema instance
  */
 static public Term run(Twine source) {
-    return (Term)run(source, SimpleTermBuilder.THE_ONE);
+    return (Term)run(source, SimpleTermSchema.THE_ONE);
 }
 
 /**
  *
  */
-static public Object run(Twine source, TermBuilder builder) {
+static public Object run(Twine source, TermSchema builder) {
     TermLexer lexer = TermLexer.make(source, builder.doesQuasis());
     TermParser parser = new TermParser(lexer, builder);
     return parser.parse();
@@ -232,11 +237,22 @@
      */
 
     TheTokens[EOFTOK]           = "EndOfFile";
+
+    TheTokens[ID]               = "ID";
+    
+    TheTokens[LiteralInteger]   = "LiteralInteger";
+    TheTokens[LiteralFloat64]   = "LiteralFloat64";
+    TheTokens[LiteralChar]      = "LiteralChar";
+    TheTokens[LiteralString]    = "LiteralString";
+
+    /* Eaten as whitespace at a higher level */
+    TheTokens[EOL]              = "EOL";
+
 }
 
 /**
  *
  */
-static public ConstList getTokenNames() {
-    return ConstList.fromArray(TheTokens);
-}
+static public final AstroSchema DEFAULT_SCHEMA =
+  new BaseSchema(ConstList.fromArray(TheTokens));
+



1.1                  e/src/jsrc/org/quasiliteral/term/TermSchema.java

Index: TermSchema.java
===================================================================
package org.quasiliteral.term;

import org.quasiliteral.astro.AstroSchema;

//This file is hereby placed in the public domain

/**
 *
 * @author <a href="mailto:markm@caplet.com">Mark Miller</a>
 */
public class TermSchema implements AstroSchema {

}