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