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