Update src/lib/Witch/Instances.hs

This commit is contained in:
Taylor Fausak 2021-07-10 14:29:58 -05:00 committed by GitHub
parent aac3a0e755
commit 88bc4efd9d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -908,7 +908,7 @@ instance From.From Rational Float where
instance From.From Rational Double where
from = fromRational
-- | TODO
-- | Uses `fromRational` as long as there isn't a loss of precision.
instance Fixed.HasResolution a => TryFrom.TryFrom Rational (Fixed.Fixed a) where
tryFrom = Utility.eitherTryFrom $ \s ->
let t = fromRational s :: Fixed.Fixed a