grisette-0.6.0.0: Symbolic evaluation as a library
Safe HaskellSafe-Inferred
LanguageHaskell2010

Grisette.Internal.Core.Data.Class.SignConversion

Synopsis

Documentation

class SignConversion ubv sbv | ubv -> sbv, sbv -> ubv where Source #

Convert values between signed and unsigned.

Methods

toSigned :: ubv -> sbv Source #

Convert unsigned value to the corresponding signed value.

toUnsigned :: sbv -> ubv Source #

Convert signed value to the corresponding unsigned value.

Instances

Instances details
SignConversion Word16 Int16 Source # 
Instance details

Defined in Grisette.Internal.Core.Data.Class.SignConversion

SignConversion Word32 Int32 Source # 
Instance details

Defined in Grisette.Internal.Core.Data.Class.SignConversion

SignConversion Word64 Int64 Source # 
Instance details

Defined in Grisette.Internal.Core.Data.Class.SignConversion

SignConversion Word8 Int8 Source # 
Instance details

Defined in Grisette.Internal.Core.Data.Class.SignConversion

SignConversion Word Int Source # 
Instance details

Defined in Grisette.Internal.Core.Data.Class.SignConversion

(KnownNat n, 1 <= n) => SignConversion (WordN n) (IntN n) Source # 
Instance details

Defined in Grisette.Internal.SymPrim.BV

Methods

toSigned :: WordN n -> IntN n Source #

toUnsigned :: IntN n -> WordN n Source #

(forall (n :: Nat). (KnownNat n, 1 <= n) => SignConversion (ubv n) (sbv n), SignConversion (ubv 1) (sbv 1)) => SignConversion (SomeBV ubv) (SomeBV sbv) Source # 
Instance details

Defined in Grisette.Internal.SymPrim.SomeBV

Methods

toSigned :: SomeBV ubv -> SomeBV sbv Source #

toUnsigned :: SomeBV sbv -> SomeBV ubv Source #

(KnownNat n, 1 <= n) => SignConversion (SymWordN n) (SymIntN n) Source # 
Instance details

Defined in Grisette.Internal.SymPrim.SymBV