Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
T
tlc4b
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
general
stups
tlc4b
Commits
0daf54dc
Commit
0daf54dc
authored
10 months ago
by
Jan Gruteser
Browse files
Options
Downloads
Patches
Plain Diff
simplify UnsupportedConstructsFinder
parent
5300fefa
No related branches found
No related tags found
No related merge requests found
Pipeline
#142546
passed
8 months ago
Stage: test
Stage: deploy
Changes
2
Pipelines
12
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/main/java/de/tlc4b/Translator.java
+1
-2
1 addition, 2 deletions
src/main/java/de/tlc4b/Translator.java
src/main/java/de/tlc4b/analysis/UnsupportedConstructsFinder.java
+1
-9
1 addition, 9 deletions
...n/java/de/tlc4b/analysis/UnsupportedConstructsFinder.java
with
2 additions
and
11 deletions
src/main/java/de/tlc4b/Translator.java
+
1
−
2
View file @
0daf54dc
...
@@ -88,8 +88,7 @@ public class Translator {
...
@@ -88,8 +88,7 @@ public class Translator {
}
}
public
void
translate
()
{
public
void
translate
()
{
UnsupportedConstructsFinder
unsupportedConstructsFinder
=
new
UnsupportedConstructsFinder
(
start
);
start
.
apply
(
new
UnsupportedConstructsFinder
());
unsupportedConstructsFinder
.
find
();
// ast transformation
// ast transformation
SeesEliminator
.
eliminateSeesClauses
(
start
,
parsedMachines
);
SeesEliminator
.
eliminateSeesClauses
(
start
,
parsedMachines
);
...
...
This diff is collapsed.
Click to expand it.
src/main/java/de/tlc4b/analysis/UnsupportedConstructsFinder.java
+
1
−
9
View file @
0daf54dc
...
@@ -12,7 +12,7 @@ import de.be4.classicalb.core.parser.node.*;
...
@@ -12,7 +12,7 @@ import de.be4.classicalb.core.parser.node.*;
import
de.tlc4b.exceptions.NotSupportedException
;
import
de.tlc4b.exceptions.NotSupportedException
;
public
class
UnsupportedConstructsFinder
extends
DepthFirstAdapter
{
public
class
UnsupportedConstructsFinder
extends
DepthFirstAdapter
{
private
final
Start
start
;
private
static
final
Set
<
Class
<?
extends
Node
>>
unsupportedClasses
=
new
HashSet
<>();
private
static
final
Set
<
Class
<?
extends
Node
>>
unsupportedClasses
=
new
HashSet
<>();
static
{
static
{
...
@@ -38,14 +38,6 @@ public class UnsupportedConstructsFinder extends DepthFirstAdapter {
...
@@ -38,14 +38,6 @@ public class UnsupportedConstructsFinder extends DepthFirstAdapter {
unsupportedClasses
.
add
(
clazz
);
unsupportedClasses
.
add
(
clazz
);
}
}
public
UnsupportedConstructsFinder
(
Start
start
)
{
this
.
start
=
start
;
}
public
void
find
()
{
start
.
apply
(
this
);
}
private
static
final
List
<
String
>
SUM_TYPE
=
new
LinkedList
<>(
private
static
final
List
<
String
>
SUM_TYPE
=
new
LinkedList
<>(
Arrays
.
asList
(
"model_clause"
,
"machine_clause"
,
"substitution"
,
"machine_parse_unit"
));
Arrays
.
asList
(
"model_clause"
,
"machine_clause"
,
"substitution"
,
"machine_parse_unit"
));
...
...
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