haskell / haskell/deepseq

Add 'Whnf{,1,2}' (or some better name) newtype

Open
#78 3 comments 1 reaction 0 assignees View on GitHub
Dominant language
Haskell
Stars
45
Forks
31
PR merge metrics
No merged PRs in 30d

Description

```haskell
newtype Whnf a = Whnf a
newtype Whnf1 f a = Whnf1 (f a)
newtype Whnf2 bi a b = Whnf2 (bi a b)

instance NFData (Whnf a) where rnf (Whnf a) = a `seq` ()
instance NFData1 (Whnf1 f) where liftRnf _ (Whnf1 as) = as `seq` ()
instance NFData2 (Whnf2 bi) where liftRnf2 _ _ (Whnf2 as) = as `seq` ()
```

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.