[commit: ghc] master: Make Data.Functor.Identity trustworthy again (8cbd25a)

git at git.haskell.org git at git.haskell.org
Thu Nov 20 09:44:12 UTC 2014


Repository : ssh://git@git.haskell.org/ghc

On branch  : master
Link       : http://ghc.haskell.org/trac/ghc/changeset/8cbd25a49051171da7c73db57ebd87bb0296c2f7/ghc

>---------------------------------------------------------------

commit 8cbd25a49051171da7c73db57ebd87bb0296c2f7
Author: Herbert Valerio Riedel <hvr at gnu.org>
Date:   Thu Nov 20 09:53:46 2014 +0100

    Make Data.Functor.Identity trustworthy again
    
    Alas `{-# LANGUAGE Safe #-}` can't be used since `Data.Coerce` isn't "safe".
    However, we use `coerce` just as an optimisation
    (see also 4ba884bdd3a9521ea92fcda8f601a7d0f3537bc1 which broke the
    safe-inferred status of `Data.Functor.Identity`), so this module at least
    deserves `{-# LANGUAGE Trustworthy #-}`.
    
    NOTE: `Data.Functor.Identity` was added to `base` in the context of #9664
    
    Reviewed By: luite
    
    Differential Revision: https://phabricator.haskell.org/D507


>---------------------------------------------------------------

8cbd25a49051171da7c73db57ebd87bb0296c2f7
 libraries/base/Data/Functor/Identity.hs | 1 +
 1 file changed, 1 insertion(+)

diff --git a/libraries/base/Data/Functor/Identity.hs b/libraries/base/Data/Functor/Identity.hs
index de7f19a..909de85 100644
--- a/libraries/base/Data/Functor/Identity.hs
+++ b/libraries/base/Data/Functor/Identity.hs
@@ -1,5 +1,6 @@
 {-# LANGUAGE AutoDeriveTypeable #-}
 {-# LANGUAGE DeriveTraversable #-}
+{-# LANGUAGE Trustworthy #-}
 
 -----------------------------------------------------------------------------
 -- |



More information about the ghc-commits mailing list