We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
BitPack (Proxy a)
1 parent e0403d2 commit 3b71c58Copy full SHA for 3b71c58
clash-prelude/src/Clash/Class/BitPack/Internal.hs
@@ -57,6 +57,7 @@ import Clash.Sized.Internal.BitVector
57
>>> :m -Prelude
58
>>> :set -XDataKinds
59
>>> import Clash.Prelude
60
+>>> import Data.Proxy
61
-}
62
63
-- | Convert data to/from a 'BitVector'. This allows functions to be defined
@@ -477,6 +478,14 @@ instance ( BitPack a
477
478
) => BitPack (Either a b)
479
480
instance BitPack a => BitPack (Maybe a)
481
+
482
+-- |
483
+-- >>> pack (Proxy @())
484
+-- 0
485
+-- >>> pack (Proxy @5)
486
487
+-- >>> pack (Proxy @Bool)
488
489
instance BitPack (Proxy a) => BitPack (Proxy a)
490
491
instance BitPack a => BitPack (Complex a)
0 commit comments