diff options
| author | Benjamin J. Culkin <bjculkin@mix.wvu.edu> | 2018-05-29 19:44:40 -0300 |
|---|---|---|
| committer | Benjamin J. Culkin <bjculkin@mix.wvu.edu> | 2018-05-29 19:44:40 -0300 |
| commit | c524f46dbd6a460b7374690244888a001023d3af (patch) | |
| tree | 8dff50b09354027879fe9b3c74c4dfc8274f25c6 /src/main/java/bjc/rgens/parser/RGrammarBuilder.java | |
| parent | e7c2ce4ba9bd684a6722baf9ce58e91dfacc8eb3 (diff) | |
Refactor to split RuleCase
RuleCase now handles its own generation.
Diffstat (limited to 'src/main/java/bjc/rgens/parser/RGrammarBuilder.java')
| -rwxr-xr-x | src/main/java/bjc/rgens/parser/RGrammarBuilder.java | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/main/java/bjc/rgens/parser/RGrammarBuilder.java b/src/main/java/bjc/rgens/parser/RGrammarBuilder.java index f34a418..fc679f1 100755 --- a/src/main/java/bjc/rgens/parser/RGrammarBuilder.java +++ b/src/main/java/bjc/rgens/parser/RGrammarBuilder.java @@ -167,7 +167,7 @@ public class RGrammarBuilder { * Is this correct, or should we be mirroring the * existing case type? */ - newCases.add(new RuleCase(NORMAL, newCase)); + newCases.add(new NormalRuleCase(newCase)); } @@ -220,7 +220,7 @@ public class RGrammarBuilder { * Is this correct, or should we be mirroring the * existing case type? */ - newCases.add(new RuleCase(NORMAL, newCase)); + newCases.add(new NormalRuleCase(newCase)); } @@ -243,7 +243,7 @@ public class RGrammarBuilder { IList<RuleCase> newCaseList = new FunctionalList<>(); for(RuleCase cse : caseList) { - newCaseList.add(new RuleCase(SPACEFLATTEN, cse.getElements())); + newCaseList.add(new FlatRuleCase(cse.getElements())); } rules.get(ruleName).replaceCases(newCaseList); |
