diff options
Diffstat (limited to 'testsuite/tests/rep-poly/RepPolyWrappedVar.hs')
-rw-r--r-- | testsuite/tests/rep-poly/RepPolyWrappedVar.hs | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/testsuite/tests/rep-poly/RepPolyWrappedVar.hs b/testsuite/tests/rep-poly/RepPolyWrappedVar.hs new file mode 100644 index 0000000000..bcc552d443 --- /dev/null +++ b/testsuite/tests/rep-poly/RepPolyWrappedVar.hs @@ -0,0 +1,15 @@ +{-# LANGUAGE DataKinds #-} +{-# LANGUAGE ScopedTypeVariables #-} +{-# LANGUAGE PolyKinds #-} +{-# LANGUAGE UnboxedTuples #-} +{-# LANGUAGE RankNTypes #-} +{-# LANGUAGE MagicHash #-} + +module RepPolyWrappedVar where + +import GHC.Exts + +primop :: forall (l :: Levity) (a :: TYPE ('BoxedRep l)). + a -> Int -> (State# RealWorld -> (# State# RealWorld, Bool #)) + -> State# RealWorld -> (# State# RealWorld, Weak# Int #) +primop = mkWeak# @a @Int @Bool |