Safe Haskell | Safe |
---|---|
Language | Haskell98 |
Deprecated: use Data.FlagSet instead
Extract and inject an Enum value into an EnumSet.
Synopsis
Documentation
T w a b
describes a contiguous set of bit indices into the word type w
where the indices are of type a
and the set of indices represent a value of type b
.
unpack :: (Integral w, Bits w, Enum a, Enum b) => T w a b -> T w a -> b Source #
Extract an enumeration value from the specified index set.
pack :: (Num w, Bits w, Enum a, Enum b) => T w a b -> b -> T w a Source #
Create an enumeration set, where an value of type b
is placed at the specified indices.