| Safe Haskell | Safe-Inferred |
|---|---|
| Language | Haskell2010 |
Grisette.Internal.Core.Data.Class.SymShift
Synopsis
- class Bits a => SymShift a where
- symShift :: a -> a -> a
- symShiftNegated :: a -> a -> a
- newtype DefaultFiniteBitsSymShift a = DefaultFiniteBitsSymShift {}
Documentation
class Bits a => SymShift a where Source #
A class for shifting operations.
The symShift function shifts the value to the left if the shift amount is
positive, and to the right if the shift amount is negative. If shifting
beyond the bit width of the value, the result is the same as shifting with
the bit width.
The symShiftNegated function shifts the value to the right if the shift
amount is positive, and to the left if the shift amount is negative. This
function is introduced to handle the asymmetry of the range of values.
Instances
| SymShift Int16 Source # | |
| SymShift Int32 Source # | |
| SymShift Int64 Source # | |
| SymShift Int8 Source # | |
| SymShift Word16 Source # | |
| SymShift Word32 Source # | |
| SymShift Word64 Source # | |
| SymShift Word8 Source # | |
| SymShift Int Source # | |
| SymShift Word Source # | |
| (Integral a, FiniteBits a) => SymShift (DefaultFiniteBitsSymShift a) Source # | |
Defined in Grisette.Internal.Core.Data.Class.SymShift Methods symShift :: DefaultFiniteBitsSymShift a -> DefaultFiniteBitsSymShift a -> DefaultFiniteBitsSymShift a Source # symShiftNegated :: DefaultFiniteBitsSymShift a -> DefaultFiniteBitsSymShift a -> DefaultFiniteBitsSymShift a Source # | |
| (KnownNat n, 1 <= n) => SymShift (IntN n) Source # | |
| (KnownNat n, 1 <= n) => SymShift (WordN n) Source # | |
| (forall (n :: Nat). (KnownNat n, 1 <= n) => SymShift (bv n)) => SymShift (SomeBV bv) Source # | |
| (KnownNat n, 1 <= n) => SymShift (SymIntN n) Source # | |
| (KnownNat n, 1 <= n) => SymShift (SymWordN n) Source # | |
newtype DefaultFiniteBitsSymShift a Source #
Constructors
| DefaultFiniteBitsSymShift | |
Fields | |