projects
/
sbp.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
21f5d36
)
formatting fixes
author
adam
<adam@megacz.com>
Mon, 26 Feb 2007 01:13:19 +0000
(20:13 -0500)
committer
adam
<adam@megacz.com>
Mon, 26 Feb 2007 01:13:19 +0000
(20:13 -0500)
darcs-hash:
20070226011319
-5007d-
f4522a5d6d74389eaef20230fee5827a7bb65423
.gz
src/edu/berkeley/sbp/Parser.java
patch
|
blob
|
history
diff --git
a/src/edu/berkeley/sbp/Parser.java
b/src/edu/berkeley/sbp/Parser.java
index
130ece9
..
f239fe5
100644
(file)
--- a/
src/edu/berkeley/sbp/Parser.java
+++ b/
src/edu/berkeley/sbp/Parser.java
@@
-9,7
+9,6
@@
import java.util.*;
/** a parser which translates an Input<Token> into a Forest<NodeType> */
public abstract class Parser<Token, NodeType> {
/** a parser which translates an Input<Token> into a Forest<NodeType> */
public abstract class Parser<Token, NodeType> {
-
protected final Table<Token> pt;
/** create a parser to parse the grammar with start symbol <tt>u</tt> */
protected final Table<Token> pt;
/** create a parser to parse the grammar with start symbol <tt>u</tt> */
@@
-38,16
+37,18
@@
public abstract class Parser<Token, NodeType> {
loc = input.getLocation();
Token nextToken = input.next();
GSS.Phase next = gss.new Phase<Token>(current, current, nextToken, loc, input.getLocation(), forest);
loc = input.getLocation();
Token nextToken = input.next();
GSS.Phase next = gss.new Phase<Token>(current, current, nextToken, loc, input.getLocation(), forest);
- if (!helpgc) {
- FileOutputStream fos = new FileOutputStream("out-"+idx+".dot");
- PrintWriter p = new PrintWriter(new OutputStreamWriter(fos));
- GraphViz gv = new GraphViz();
- for(Object n : next)
- ((Node)n).toGraphViz(gv);
- gv.dump(p);
- p.flush();
- p.close();
- }
+
+ /*
+ FileOutputStream fos = new FileOutputStream("out-"+idx+".dot");
+ PrintWriter p = new PrintWriter(new OutputStreamWriter(fos));
+ GraphViz gv = new GraphViz();
+ for(Object n : current)
+ ((Node)n).toGraphViz(gv);
+ gv.dump(p);
+ p.flush();
+ p.close();
+ */
+
count = next.size();
if (current.isDone()) return (Forest<NodeType>)gss.finalResult;
current = next;
count = next.size();
if (current.isDone()) return (Forest<NodeType>)gss.finalResult;
current = next;