You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
> let a = { b = 0.5; }; in a.b * 2
=> value is a float while an integer was expected, at (string):1:26
> 0.5 * 2
=> 1
> let a = 0.5; in a * 2
=> 1
> let a = { b = 0.5; }; c = a.b; in c * 2
=> value is a float while an integer was expected, at (string):1:35
> let a = { b = 0.5; }; c = a.b; in builtins.seq c (c * 2)
=> 1
The text was updated successfully, but these errors were encountered:
> let a = { b = 0.5; }; in a.b * 2.0
=> 1
> let a = { b = 0.5; }; in a.b * (2.0 + 0.5)
=> value is a float while an integer was expected, at (string):1:26
> (0.5 + 0.5) * (2.0 + 0.5)
=> value is a float while an integer was expected, at (string):1:1
LisannaAtHome
changed the title
Can't use a float in multiplication with an int if accessed from an attrset
Non-trivial float multiplication is broken
Aug 18, 2018
The text was updated successfully, but these errors were encountered: