mirror of
https://github.com/JonathanFleischmann/CompilerULTIMATE.git
synced 2024-12-28 17:08:03 +00:00
remove continue
This commit is contained in:
parent
b61af71076
commit
f97f3a3b3a
@ -25,7 +25,6 @@ stmt : 'if' '(' expr ')' block ('else' block)? #If
|
||||
| 'return' expr ';' #Return
|
||||
| 'return' ';' #ReturnVoid
|
||||
| 'break' ';' #Break
|
||||
| 'continue' ';' #Continue
|
||||
| assign ';' #Assignment
|
||||
| stmtexpr ';' #StatementExpressionstmt
|
||||
;
|
||||
|
@ -61,11 +61,6 @@ public class StatementGenerator extends DecafBaseVisitor<Statement> {
|
||||
return new Break();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Statement visitContinue(DecafParser.ContinueContext ctx) {
|
||||
return new Continue();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Statement visitAssignment(DecafParser.AssignmentContext ctx) {
|
||||
return generateAssign(ctx.assign());
|
||||
|
@ -1,5 +0,0 @@
|
||||
package de.maishai.ast.records;
|
||||
|
||||
|
||||
public record Continue() implements Statement {
|
||||
}
|
@ -1,16 +1,4 @@
|
||||
package de.maishai.ast.records;
|
||||
|
||||
import de.maishai.ast.records.Break;
|
||||
import de.maishai.ast.records.Continue;
|
||||
import de.maishai.ast.records.DoWhile;
|
||||
import de.maishai.ast.records.For;
|
||||
import de.maishai.ast.records.IfElse;
|
||||
import de.maishai.ast.records.MethodCall;
|
||||
import de.maishai.ast.records.New;
|
||||
import de.maishai.ast.records.Node;
|
||||
import de.maishai.ast.records.Return;
|
||||
import de.maishai.ast.records.ReturnVoid;
|
||||
import de.maishai.ast.records.While;
|
||||
|
||||
public sealed interface Statement extends Node permits Assignment, Break, Continue, DoWhile, For, IfElse, MethodCall, New, Return, ReturnVoid, While {
|
||||
public sealed interface Statement extends Node permits Assignment, Break, DoWhile, For, IfElse, MethodCall, New, Return, ReturnVoid, While {
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user