Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
SableCC STUPS
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Model registry
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
general
stups
SableCC STUPS
Commits
3729e160
Commit
3729e160
authored
3 years ago
by
dgelessus
Browse files
Options
Downloads
Patches
Plain Diff
Adjust a few types to match new generics in generated node classes
parent
b876187e
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/main/java/org/sablecc/sablecc/AddAstProductions.java
+3
-3
3 additions, 3 deletions
src/main/java/org/sablecc/sablecc/AddAstProductions.java
src/main/java/org/sablecc/sablecc/Inlining.java
+2
-2
2 additions, 2 deletions
src/main/java/org/sablecc/sablecc/Inlining.java
with
5 additions
and
5 deletions
src/main/java/org/sablecc/sablecc/AddAstProductions.java
+
3
−
3
View file @
3729e160
...
@@ -26,7 +26,7 @@ import java.io.*;
...
@@ -26,7 +26,7 @@ import java.io.*;
public
class
AddAstProductions
extends
DepthFirstAdapter
public
class
AddAstProductions
extends
DepthFirstAdapter
{
{
List
<
A
AstProd
>
listAstProd
=
new
LinkedList
<>();
List
<
P
AstProd
>
listAstProd
=
new
LinkedList
<>();
private
boolean
firstAlt
;
private
boolean
firstAlt
;
public
AddAstProductions
()
public
AddAstProductions
()
...
@@ -95,8 +95,8 @@ public class AddAstProductions extends DepthFirstAdapter
...
@@ -95,8 +95,8 @@ public class AddAstProductions extends DepthFirstAdapter
}
}
}
}
List
<
A
Elem
>
listElems
;
List
<
P
Elem
>
listElems
;
List
<
A
AstAlt
>
listOfAstAlts
;
List
<
P
AstAlt
>
listOfAstAlts
;
public
void
error
(
Token
token
)
public
void
error
(
Token
token
)
{
{
...
...
This diff is collapsed.
Click to expand it.
src/main/java/org/sablecc/sablecc/Inlining.java
+
2
−
2
View file @
3729e160
...
@@ -79,7 +79,7 @@ public class Inlining
...
@@ -79,7 +79,7 @@ public class Inlining
Once we detect that the production can be inline,
Once we detect that the production can be inline,
we try to inline each of its alternatives.
we try to inline each of its alternatives.
*/
*/
List
<
A
Alt
>
listOfAlts
=
new
LinkedList
<>();
List
<
P
Alt
>
listOfAlts
=
new
LinkedList
<>();
for
(
int
i
=
0
;
i
<
alts
.
length
;
i
++)
for
(
int
i
=
0
;
i
<
alts
.
length
;
i
++)
{
{
listOfAlts
.
addAll
(
inlineAlternative
(
alts
[
i
])
);
listOfAlts
.
addAll
(
inlineAlternative
(
alts
[
i
])
);
...
@@ -107,7 +107,7 @@ public class Inlining
...
@@ -107,7 +107,7 @@ public class Inlining
return
false
;
return
false
;
}
}
List
<
A
Alt
>
removeAlternativeDoubloonsFromInlinedProduction
(
List
<
A
Alt
>
inlinedAlternatives
)
List
<
P
Alt
>
removeAlternativeDoubloonsFromInlinedProduction
(
List
<
P
Alt
>
inlinedAlternatives
)
{
{
AAlt
[]
alts
=
inlinedAlternatives
.
toArray
(
new
AAlt
[
0
]);
AAlt
[]
alts
=
inlinedAlternatives
.
toArray
(
new
AAlt
[
0
]);
List
<?>[]
theWhole
=
new
List
<?>[
alts
.
length
];
List
<?>[]
theWhole
=
new
List
<?>[
alts
.
length
];
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment