mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
transformer: fix precalculations of simple expressions involving floating literals, with -prod (fix VSL tests with -prod)
This commit is contained in:
@@ -866,8 +866,8 @@ pub fn (mut t Transformer) infix_expr(mut node ast.InfixExpr) ast.Expr {
|
||||
ast.FloatLiteral {
|
||||
match mut node.right {
|
||||
ast.FloatLiteral {
|
||||
left_val := node.left.val.f32()
|
||||
right_val := node.right.val.f32()
|
||||
left_val := node.left.val.f64()
|
||||
right_val := node.right.val.f64()
|
||||
match node.op {
|
||||
.eq {
|
||||
return ast.BoolLiteral{
|
||||
|
||||
Reference in New Issue
Block a user