cosmetics.

This commit is contained in:
Manuel Friedli 2024-03-24 04:35:09 +01:00
parent 6e0b8f950d
commit 3235cbab7b
Signed by: manuel
GPG key ID: 41D08ABA75634DA1
3 changed files with 1 additions and 8 deletions

View file

@ -29,13 +29,6 @@ public enum TokenType {
IF, IF,
ELSE; ELSE;
public boolean isBinaryOperator() {
return switch (this) {
case PLUS, MINUS, MULT, DIV, MOD, EXP -> true;
default -> false;
};
}
@NotNull @NotNull
public Option<Integer> precedence() { public Option<Integer> precedence() {
return Option.of(switch (this) { return Option.of(switch (this) {

View file

@ -55,7 +55,6 @@ public class Generator {
this.printer.rawLine("global _start"); this.printer.rawLine("global _start");
this.printer.blank(); this.printer.blank();
this.printer.label("_start"); this.printer.label("_start");
} }
private void generateFooter() { private void generateFooter() {

View file

@ -124,6 +124,7 @@ final class StmtVisitor {
this.generator.printer.label(afterElseLabel); this.generator.printer.label(afterElseLabel);
} }
@NotNull
private String createNextLabel() { private String createNextLabel() {
return "label" + (this.labelCounter++); return "label" + (this.labelCounter++);
} }