From 8e7089a5d6ba1f4f50a90133bb50bc5c6c554aff Mon Sep 17 00:00:00 2001 From: Santo Cariotti Date: Thu, 13 Jun 2024 11:00:06 +0200 Subject: Set up visitor (#3) Co-authored-by: geno --- src/ast/types/IntType.java | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 src/ast/types/IntType.java (limited to 'src/ast/types/IntType.java') diff --git a/src/ast/types/IntType.java b/src/ast/types/IntType.java new file mode 100644 index 0000000..9f4b250 --- /dev/null +++ b/src/ast/types/IntType.java @@ -0,0 +1,10 @@ +package com.clp.project.ast.types; + +/** + * An integer type. + */ +public class IntType extends Type { + public String toPrint(String prefix) { + return prefix + "Int\n"; + } +} -- cgit v1.2.3-71-g8e6c