fast-math
fast-math copied to clipboard
Typo in comments
At https://github.com/liyang/fast-math/blob/86573174151c4c683f2d1fb29dbfcb135ac9a2d6/Numeric/FastMath/Approximation.hs#L125 it says
-- NOTE: It is important that these rules should fire after the distributivity
-- rules. This ensures that
--
-- > x*x+x*y
--
-- gets simplified to
--
-- > x*(x+y)
--
-- rather than
--
-- > x+x+x*y
Assumedly this should say 2*x + x*y
, since x*x
!= x+x
.