Skip to content
Snippets Groups Projects
Commit fe6994ed authored by Josef Svenningsson's avatar Josef Svenningsson Committed by Ryan Scott
Browse files

Add GNFData instance for unboxed types (#45)

parent a2d507af
No related branches found
No related tags found
No related merge requests found
......@@ -179,6 +179,13 @@ instance GNFData arity a => GNFData arity (M1 i c a) where
grnf args = grnf args . unM1
{-# INLINEABLE grnf #-}
#if __GLASGOW_HASKELL__ >= 800
-- @since 1.4.5.0
instance GNFData arity (URec a) where
grnf _ = rwhnf
{-# INLINEABLE grnf #-}
#endif
instance (GNFData arity a, GNFData arity b) => GNFData arity (a :*: b) where
grnf args (x :*: y) = grnf args x `seq` grnf args y
{-# INLINEABLE grnf #-}
......
# Changelog for [`deepseq` package](http://hackage.haskell.org/package/deepseq)
## 1.4.5.0
* Add `GNFData` for URec
This will enable deriving NFData instances for unboxed types
## 1.4.4.0 *Sep 2018*
* Bundled with GHC 8.6.1
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment