Add `instance {Bits,FiniteBits} Bool`
authorHerbert Valerio Riedel <hvr@gnu.org>
Sun, 24 Nov 2013 12:14:16 +0000 (13:14 +0100)
committerHerbert Valerio Riedel <hvr@gnu.org>
Sun, 24 Nov 2013 12:19:19 +0000 (13:19 +0100)
commit775d13d9c0d6d7247fb5ea6ed5ab973495dda58f
tree1cd94be69976e5eb52acd5494eb9eeb1f5351eb9
parent14527c19a443e30e5d919beb628f554a9a21e391
Add `instance {Bits,FiniteBits} Bool`

This interprets `Bool` as an 1-bit "unsigned" bit-field and provides a
simple (not particularily optimized) implementation to that end.

See "Proposal: Add `instance Bits Bool`" by @ekmett, Nov 2013,

 http://permalink.gmane.org/gmane.comp.lang.haskell.libraries/20663

Signed-off-by: Herbert Valerio Riedel <hvr@gnu.org>
libraries/base/Data/Bits.hs