30 lines
627 B
C#
30 lines
627 B
C#
namespace Lunar.Evil_Calculator
|
|
{
|
|
internal class Token
|
|
{
|
|
public enum TokenType
|
|
{
|
|
Operator,
|
|
Operand,
|
|
}
|
|
|
|
public TokenType tokenType;
|
|
public string value;
|
|
public int? priority;
|
|
|
|
|
|
public Token(TokenType tokenType, string value)
|
|
{
|
|
this.tokenType = tokenType;
|
|
this.value = value;
|
|
}
|
|
|
|
public Token(TokenType tokenType, string value, int priority)
|
|
{
|
|
this.tokenType = tokenType;
|
|
this.value = value;
|
|
this.priority = priority;
|
|
}
|
|
}
|
|
}
|