Repository : ssh://darcs.haskell.org//srv/darcs/packages/ghc-prim

On branch  : ghc-generics

http://hackage.haskell.org/trac/ghc/changeset/888b38984aeb9008b9bb6f12a6ee5c2faa105c3d

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

commit 888b38984aeb9008b9bb6f12a6ee5c2faa105c3d
Author: Jose Pedro Magalhaes <[email protected]>
Date:   Wed Jul 27 15:33:50 2011 +0200

    Generics: implement automatic deriving of Generic1.

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

 GHC/CString.hs  |    1 -
 GHC/Generics.hs |    5 +++++
 2 files changed, 5 insertions(+), 1 deletions(-)

diff --git a/GHC/CString.hs b/GHC/CString.hs
index d51eaf6..2efb47f 100644
--- a/GHC/CString.hs
+++ b/GHC/CString.hs
@@ -16,7 +16,6 @@
 -----------------------------------------------------------------------------
 
 {-# OPTIONS_GHC -XNoImplicitPrelude #-}
-{-# OPTIONS_GHC -XNoGenerics        #-}
 {-# OPTIONS_GHC -XBangPatterns      #-}
 
 module GHC.CString (
diff --git a/GHC/Generics.hs b/GHC/Generics.hs
index bdaa702..4dc260e 100644
--- a/GHC/Generics.hs
+++ b/GHC/Generics.hs
@@ -22,12 +22,17 @@ module GHC.Generics  (
   -- * Generic type classes
   , Generic(..), Generic1(..)
 
+  , genUnsafeCoerce
   ) where
   
 -- We use some base types
 import {-# SOURCE #-} GHC.Types
 -- We need this to give the Generic instances in ghc-prim
 import GHC.CString ()
+import GHC.Prim (unsafeCoerce#)
+
+genUnsafeCoerce :: a -> b
+genUnsafeCoerce = unsafeCoerce#
 
 
--------------------------------------------------------------------------------
 -- Representation types



_______________________________________________
Cvs-libraries mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/cvs-libraries

Reply via email to