/**
 * Tokens for use in parsers.
 */
public class Token {
    /*
    Me: Mom, can we have ADTs?
    Mom: We already have ADTs in Java
    ADTs in Java:
     */
    public record Number(BigInteger num) {}
    public record Word(String name, BigInteger prefix) {}
    public record SequenceBuilder(BigInteger[] initial, Token[] operation) {}
    public record MacroStart(String name) {}
    public record MacroEnd() {}
}

comments