(it iter.Seq[ast.Constant])
| 1399 | } |
| 1400 | |
| 1401 | func evalFloatMin(it iter.Seq[ast.Constant]) (ast.Constant, error) { |
| 1402 | min := math.MaxFloat64 |
| 1403 | for c := range it { |
| 1404 | floatNum, err := c.Float64Value() |
| 1405 | if err != nil { |
| 1406 | return ast.Constant{}, err |
| 1407 | } |
| 1408 | if floatNum < min { |
| 1409 | min = floatNum |
| 1410 | } |
| 1411 | } |
| 1412 | return ast.Float64(min), nil |
| 1413 | } |
| 1414 | |
| 1415 | func evalSum(it iter.Seq[ast.Constant]) (ast.Constant, error) { |
| 1416 | var sum int64 |
no test coverage detected