| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
Michelson.Interpret.Unpack
Description
Module, carrying logic of UNPACK instruction.
This is nearly symmetric to adjacent Pack.hs module.
When implementing this the following sources were used:
Synopsis
- newtype UnpackError = UnpackError {}
- unpackValue :: UnpackedValScope t => LByteString -> Either UnpackError (Value t)
- unpackValue' :: UnpackedValScope t => ByteString -> Either UnpackError (Value t)
- unpackInstr' :: ByteString -> Either UnpackError [ExpandedOp]
- decodeContract :: Get Contract
Documentation
newtype UnpackError Source #
Any decoding error.
Constructors
| UnpackError | |
Fields | |
Instances
| Eq UnpackError Source # | |
Defined in Util.Binary | |
| Show UnpackError Source # | |
Defined in Util.Binary Methods showsPrec :: Int -> UnpackError -> ShowS # show :: UnpackError -> String # showList :: [UnpackError] -> ShowS # | |
| Exception UnpackError Source # | |
Defined in Util.Binary Methods toException :: UnpackError -> SomeException # fromException :: SomeException -> Maybe UnpackError # displayException :: UnpackError -> String # | |
| Buildable UnpackError Source # | |
Defined in Util.Binary Methods build :: UnpackError -> Builder # | |
unpackValue :: UnpackedValScope t => LByteString -> Either UnpackError (Value t) Source #
Deserialize bytes into the given value.
Suitable for UNPACK operation only.
unpackValue' :: UnpackedValScope t => ByteString -> Either UnpackError (Value t) Source #
Like unpackValue, for strict byte array.
unpackInstr' :: ByteString -> Either UnpackError [ExpandedOp] Source #
Deserialize an instruction into the given value.