Fix literal floats evaluating wrong values
This commit is contained in:
@@ -76,7 +76,7 @@ double Evaluator::EvaluateFloatExpression(BoundExpression *expression) {
|
||||
throw EvaluationException("Can't evaluate expression as integer, it will return an integer, not a float.");
|
||||
}
|
||||
switch (expression->GetKind()){
|
||||
case BoundExpressionKind ::LiteralFloat: return ((BoundLiteralIntegerExpression*)expression)->GetValue();
|
||||
case BoundExpressionKind ::LiteralFloat: return ((BoundLiteralFloatExpression*)expression)->GetValue();
|
||||
case BoundExpressionKind ::Binary: return this -> EvaluateFloatBinary((BoundBinaryExpression*)expression);
|
||||
|
||||
case BoundExpressionKind ::LiteralInteger:
|
||||
|
||||
Reference in New Issue
Block a user