Amogulator/Suslang/Token.cs
2023-03-14 12:53:56 +01:00

33 lines
427 B
C#

namespace Amogulator.Suslang;
public enum TokenType {
Eof,
Invalid,
Id,
Int,
Hex,
Decimal,
String,
True,
False,
LParen,
RParen,
Plus,
Minus,
Asterisk,
Slash,
Percent,
Dot,
}
public struct Position {
public int index;
public int line, col;
}
public struct Token {
public TokenType type;
public Position position;
public int length;
}