Added an error for constant expressions.

This commit is contained in:
arookas 2015-12-28 14:20:44 -05:00
parent 5f3c86669b
commit 6be1779781

View file

@ -119,7 +119,12 @@ namespace arookas {
public sunAssignConstantException(sunIdentifier node)
: base(node) { }
}
class sunConstantExpressionException : sunNodeException<sunNode> {
public override string Message { get { return "Expression must be constant."; } }
public sunConstantExpressionException(sunNode node)
: base(node) { }
}
class sunRedeclaredParameterException : sunNodeException<sunIdentifier> {
public override string Message { get { return String.Format("Redeclared parameter '{0}'.", Node.Value); } }