Skip to content

Commit

Permalink
fixed an error in JLS3; made progress in convergence; added XPath exp…
Browse files Browse the repository at this point in the history
…ressions for lists of nonterminals; split preferLALR

git-svn-id: https://slps.svn.sourceforge.net/svnroot/slps@383 ab42f6e0-554d-0410-b580-99e487e6eeb2
  • Loading branch information
grammarware committed Oct 28, 2008
1 parent ba30e96 commit 92b979a
Show file tree
Hide file tree
Showing 8 changed files with 32 additions and 101 deletions.
3 changes: 2 additions & 1 deletion topics/java/lci/java.lcf
Expand Up @@ -96,8 +96,9 @@
<branch>
<input>doc1</input>
<perform>correct-doc1</perform>
<perform>generalizeModifiers-doc1</perform>
<perform>generalizeNames-doc1</perform>
<perform>preferLALR</perform>
<perform>refactor-doc1</perform>
</branch>
</target>

Expand Down
Binary file modified topics/java/lci/snapshot/architecture_large.pdf
Binary file not shown.
Binary file modified topics/java/lci/snapshot/architecture_small.pdf
Binary file not shown.
17 changes: 17 additions & 0 deletions topics/java/lci/xbgf/correct-app3.xbgf
Expand Up @@ -110,4 +110,21 @@ Annotation:
</bgf:expression>
</xbgf:replace>

<!-- ISSUE CORRECT SPECERROR
lacking definition copied from JLS2 -->
<xbgf:define>
<bgf:production>
<nonterminal>ForUpdate</nonterminal>
<bgf:expression>
<sequence>
<bgf:expression>
<nonterminal>StatementExpression</nonterminal>
</bgf:expression>
<bgf:expression>
<nonterminal>MoreStatementExpressions</nonterminal>
</bgf:expression>
</sequence>
</bgf:expression>
</bgf:production>
</xbgf:define>
</xbgf:sequence>
12 changes: 11 additions & 1 deletion topics/java/lci/xbgf/generalizeNames-doc1.xbgf
Expand Up @@ -55,5 +55,15 @@ vs

<!--ISSUE REFACTOR EBNF-->
<xbgf:deyaccify>QualifiedIdentifier</xbgf:deyaccify>


<!-- ISSUE REFACTOR
use another name -->
<xbgf:rename>
<nonterminal>
<from>QualifiedIdentifier</from>
<to>Name</to>
</nonterminal>
</xbgf:rename>


</xbgf:sequence>
Expand Up @@ -14,15 +14,6 @@
<nonterminal>Statement</nonterminal>
</xbgf:vertical>

<!-- ISSUE REFACTOR
use another name -->
<xbgf:rename>
<nonterminal>
<from>QualifiedIdentifier</from>
<to>Name</to>
</nonterminal>
</xbgf:rename>

<!-- ISSUE REFACTOR
- Fail: ClassOrInterfaceType.
- [], ;([n(ClassType), n(InterfaceType)])
Expand Down Expand Up @@ -70,96 +61,6 @@
</in>
</xbgf:fold>

<!-- ISSUE REFACTOR GENERALIZE
- Fail: FieldDeclaration.
- [], ,([?(n(FieldModifiers)), n(Type), n(VariableDeclarators), t((;))])
vs.
- [], ,([?(n(Modifiers)), n(Type), n(VariableDeclarators), t((;))])
(and many similar ones)
-->
<xbgf:vertical>
<nonterminal>ClassModifier</nonterminal>
</xbgf:vertical>
<xbgf:vertical>
<nonterminal>InterfaceModifier</nonterminal>
</xbgf:vertical>
<xbgf:vertical>
<nonterminal>ConstructorModifier</nonterminal>
</xbgf:vertical>
<xbgf:vertical>
<nonterminal>AbstractMethodModifier</nonterminal>
</xbgf:vertical>
<xbgf:vertical>
<nonterminal>MethodModifier</nonterminal>
</xbgf:vertical>
<xbgf:vertical>
<nonterminal>FieldModifier</nonterminal>
</xbgf:vertical>
<xbgf:vertical>
<nonterminal>ConstantModifier</nonterminal>
</xbgf:vertical>
<xbgf:rename>
<nonterminal>
<from>ClassModifier</from>
<to>Modifier</to>
</nonterminal>
</xbgf:rename>
<xbgf:unite>
<add>InterfaceModifier</add>
<to>Modifier</to>
</xbgf:unite>
<xbgf:unite>
<add>ConstructorModifier</add>
<to>Modifier</to>
</xbgf:unite>
<xbgf:unite>
<add>AbstractMethodModifier</add>
<to>Modifier</to>
</xbgf:unite>
<xbgf:unite>
<add>MethodModifier</add>
<to>Modifier</to>
</xbgf:unite>
<xbgf:unite>
<add>FieldModifier</add>
<to>Modifier</to>
</xbgf:unite>
<!-- NB: was a weird name (plural) -->
<xbgf:unite>
<add>ConstantModifier</add>
<to>Modifier</to>
</xbgf:unite>
<xbgf:rename>
<nonterminal>
<from>ClassModifiers</from>
<to>Modifiers</to>
</nonterminal>
</xbgf:rename>
<xbgf:unite>
<add>ConstantModifiers</add>
<to>Modifiers</to>
</xbgf:unite>
<xbgf:unite>
<add>InterfaceModifiers</add>
<to>Modifiers</to>
</xbgf:unite>
<xbgf:unite>
<add>ConstructorModifiers</add>
<to>Modifiers</to>
</xbgf:unite>
<xbgf:unite>
<add>AbstractMethodModifiers</add>
<to>Modifiers</to>
</xbgf:unite>
<xbgf:unite>
<add>MethodModifiers</add>
<to>Modifiers</to>
</xbgf:unite>
<xbgf:unite>
<add>FieldModifiers</add>
<to>Modifiers</to>
</xbgf:unite>

<!-- ISSUE REFACTOR GENERALIZE
- Fail: MethodHeader.
- [], ,([?(n(MethodModifiers)), n(ResultType), n(MethodDeclarator), ?(n(Throws))])
Expand Down
1 change: 1 addition & 0 deletions topics/presentation/metrics/listbottoms.xpath
@@ -0,0 +1 @@
/*/*[not(*//nonterminal)]/nonterminal[not(text()=../preceding-sibling::*/nonterminal/text())]
1 change: 1 addition & 0 deletions topics/presentation/metrics/listtops.xpath
@@ -0,0 +1 @@
/*/*/nonterminal[not(text()=/*/*/*//nonterminal/text()) and not(text()=../preceding-sibling::*/nonterminal/text())]

0 comments on commit 92b979a

Please sign in to comment.