WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
Skip to content

Commit 0fe3725

Browse files
committed
fromIntegral -> getScalar
1 parent 49d6195 commit 0fe3725

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

test/ArrayFire/ArithSpec.hs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,9 +98,10 @@ shouldBeEps :: Array Double -> Array Double -> Expectation
9898
actual `shouldBeEps` expected = expect err_msg (cmpEps actual expected)
9999
where
100100
err_msg = "expected: " ++ show expected ++ "\n but got: " ++ show actual
101+
cmpEps :: Array Double -> Array Double -> Bool
101102
cmpEps a b =
102103
let x :: Double
103-
x = fromIntegral $ Prelude.abs $ a - b
104+
x = getScalar $ Prelude.abs $ a - b
104105
in x <= 1e-14
105106

106107
expect :: String -> Bool -> Expectation

0 commit comments

Comments
 (0)