checkpoint
[sbp.git] / TODO
1 _____________________________________________________________________________
2 Immediately
3
4   - do Forest/Tree still need a Region?
5   - reconsider the degree of genericization
6   - GraphViz stuff pollutes the API...
7   - Forest needs a "manual access" API
8       - the unwrap bit in Forest makes it really hard to expose an API for forests
9
10   - evil problems with      (x y? z /ws)
11   - ParseFailed, GSS, Walk, Parser, Sequence, Forest
12   - copyright notices
13   - documentation
14
15   - grammar highlighting?
16   - comment indentation vs block indentation?
17   - { and } in <pre>
18   - recursive { { foo } }
19
20 ______________________________________________________________________________
21 v1.1
22
23   - finalize metagrammar and rdp-op's
24   - write some grammars
25       - Java grammar
26       - TeX (math?)
27       - URL (RFC)
28       - RFC2822 (email message/headers)
29   - clean up the whole Walk situation (?)
30
31
32 ______________________________________________________________________________
33 Soon
34
35   - serialization of parse tables
36
37   - "ambiguity modulo dropped fragments"?
38        - can this be checked statically?
39        - eliminated statically?
40
41   - substring parsing for better error messages
42
43   - Parameterized LR
44   - "Regular Right Part" grammars (NP Chapman, etc)
45   - Attribute unification
46
47   - inference of rejections for literals
48   - "prefer whitespace higher up" (?)
49
50   - Labeled edges on trees (associate a label with each slot in the
51     child array in Forest.Body?  might make equality tough) --
52     equivalent to Feature Structures.  Colon-labeling.
53
54 ______________________________________________________________________________
55 Later
56
57   - Partly-Linear-PATR? (O(n^6) unification grammar)
58
59   - Implement a k-token peek buffer (for each state, see if it "dead
60     ends" during the next k Phases based solely on state -- ignoring
61     result SPPF)
62
63   - Arrange for the SPPF corresponding to dropped subtrees to never be
64     generated (or merged, etc)
65
66   - Is there any way we can avoid creating a GSS.Node instance for
67     nodes which are transient in the sense that they have only one
68     eligible reduction?
69
70   - Re-read Rekers, particularly the stuff on optimal sharing
71
72   - Isolate the Element objects from Parse.Table/GSS so we can move
73     towards compilation.
74
75   - consider allowing a Forest.Body to represent some other Tree whose
76     Body's should be [recursively] considered part of this Forest.
77
78       - perhaps not: right now we have a nice situation where
79         Forest.Ref instances become immutable once iterator()ed.  This
80         also gives us a strong place to to culling with the certainty
81         that we won't throw out a Body which would later be salvaged
82         by some yet-to-be-added dependency.
83
84   - Figure out if there is a way to:
85
86       - allow unwrapping of children other than the very last one.
87
88       - fold repetitions into an array form in Forest, before
89         conversion to Tree.  The major problem here is that multiple
90         tree-arrays are possible, all of different lengths.  Worse,
91         even if they're all the same length, not all elements belong
92         in the same "possibility vector" as all others.  You
93         essentially need a GSS to represent the array, which perhaps
94         is what the unfolded form was in the first place.
95
96   - Wikipedia grammar (needs to be both lexerless and boolean)
97
98   - Boolean Parsing
99       => Ordered Choice (";" operator)
100
101   - bring back in parse-table phase resolution of precedence (just
102     like associativity).  This can be inferred from the use of ">"
103     when the rules are in one of these special forms:
104
105        E ::=  E     _
106            >  _     E
107
108        E ::=  _     E
109            >  E  _  E
110
111        E ::=  E  _  E
112            >  E  _  E
113
114     where "_" is anything and "E" is the defining nonterminal.
115     Essentially what we're looking for is the situation where the
116     leftmost portion of one rule produces another rule, and the
117     rightmost portion of the latter produces the former.
118
119     I'm not 100% certain that this is as "strong" as the prefer/avoid
120     form (try to prove this, you probably can), but it's "what people
121     intend" most of the time.
122
123   - implement Johnstone's algorithm for "reduced, resolved LR
124     tables" to eliminate superfluous reductions on
125     epsilon-transitions.
126
127 ______________________________________________________________________________
128 Neat Ideas
129
130   - Rekers & Koorn note that GLR Substring Parsing can be used to do
131     really elegant and generalized "autocompletion".
132
133
134 ______________________________________________________________________________
135 Ideas for the Future
136
137 - Incremental parse table construction
138 - "lazy GLR" and "lazy trees" -> language with first-class CF matching
139     - perhaps linear boolean grammars instead? (linear time, quad space)
140 - Forest parsing => chained parsers
141 - unification parsing, attributes, etc
142 - RRP grammars?
143 - Take another stab at maximal-match?  Nonterminal not-followed-by is
144   too strong.
145 - Error recovery based on substring parsing