_____________________________________________________________________________
Immediately
- * pick back up cleaning up end of Parser.java (Reduction)
-
- - [more] sensible tree-printout
-
- - revamp Tib.Block (do it all in the parser using indent/dedent?)
-
- - more natural phrasing of metagrammar?
- - finalize metagrammar and rdp-op's
+ - clean up the whole Walk situation (?)
- decent/better error messages
- fix the location stuff, it's broken
+
+______________________________________________________________________________
+v1.1
+
+ - finalize metagrammar and rdp-op's
- write some grammars
- Java grammar
- TeX (math?)
______________________________________________________________________________
Soon
- - substring parsing for better error messages
+ - serialization of parse tables
- - clean up the whole Walk situation
+ - "ambiguity modulo dropped fragments"?
+ - can this be checked statically?
+ - eliminated statically?
+ - substring parsing for better error messages
- "lift" cases:
- right now I can only lift the last child in a forest... begs
the question of what the right representation for Forests is
- "Regular Right Part" grammars (NP Chapman, etc)
- Attribute unification
- - serialization of parse tables
- inference of rejections for literals
- "prefer whitespace higher up" (?)
- - "ambiguity modulo dropped fragments"?
- - can this be checked statically?
- - eliminated statically?
+
______________________________________________________________________________
Later
public Topology<Tok> walkAtom(Atom r) { cs = cs.union(r); return cs; }
}
- class First<Tok extends Token> extends WalkTokenSet<Tok> {
+ static class First<Tok extends Token> extends WalkTokenSet<Tok> {
public First(Topology<Tok> cs, Walk.Cache cache) { super(cs, cache); }
public Topology<Tok> sequence(Sequence seq) {
for(Position p = seq.firstp(); p!=null && !p.isLast(); p = p.next()) {
Sequence a = (Sequence)x;
Position mp = null;
for(Position pos = a.firstp(); pos != null && !pos.isLast(); pos = pos.next()) {
- if (matched) cs = cs.union(new First<Tok>(cs.empty(), c).walk(pos.element()));
+ if (matched) cs = cs.union(c.first(pos.element(), cs.empty()));
if (pos.isLast()) { matched = (matched && pos.element().possiblyEpsilon(c)); continue; }
boolean good = false;
if (e instanceof Atom) {
public HashMap<Element,Topology> follow = new HashMap<Element,Topology>();
public HashMapBag<Element,Element> ys = new HashMapBag<Element,Element>();
public HashMap<Element,Topology> atoms = new HashMap<Element,Topology>();
+ public <Tok extends Token> Topology<Tok> first(Element e, Topology<Tok> empty) {
+ return new Walk.First<Tok>(empty, this).walk(e);
+ }
}
}