• Herbert Valerio Riedel's avatar
    Weaken constraints on Data.Complex functions · 7b04d35a
    Herbert Valerio Riedel authored
    The RealFloat data type context was dropped from Data.Complex some time
    ago (see ea280135). However, the rest of
    the API in that module was left as-is even though many of the accessors
    in that module would work with much more general types now.
    This change simplifies the signatures of the functions above, which in
    the current API all unnecessarily take a RealFloat constraint that they
    don't use (and which may cause to pass around superflous type-class
        realPart  :: Complex a -> a
        imagPart  :: Complex a -> a
        conjugate :: Num a => Complex a -> Complex a
        mkPolar   :: Floating a => a -> a -> Complex a
        cis       :: Floating a => a -> Complex a
    This was originally proposed by Edward Kmett in
    Signed-off-by: Herbert Valerio Riedel's avatarHerbert Valerio Riedel <hvr@gnu.org>
To find the state of this project's repository at the time of any of these versions, check out the tags..
changelog.md 6.06 KB