Safe Haskell | None |
---|---|
Language | Haskell2010 |
Untyped Michelson values (i. e. type of a value is not statically known).
Synopsis
- data Value' op
- = ValueInt Integer
- | ValueString MText
- | ValueBytes InternalByteString
- | ValueUnit
- | ValueTrue
- | ValueFalse
- | ValuePair (Value' op) (Value' op)
- | ValueLeft (Value' op)
- | ValueRight (Value' op)
- | ValueSome (Value' op)
- | ValueNone
- | ValueNil
- | ValueSeq (NonEmpty $ Value' op)
- | ValueMap (NonEmpty $ Elt op)
- | ValueLambda (NonEmpty op)
- data Elt op = Elt (Value' op) (Value' op)
- newtype InternalByteString = InternalByteString ByteString
- unInternalByteString :: InternalByteString -> ByteString
Documentation
ValueInt Integer | |
ValueString MText | |
ValueBytes InternalByteString | |
ValueUnit | |
ValueTrue | |
ValueFalse | |
ValuePair (Value' op) (Value' op) | |
ValueLeft (Value' op) | |
ValueRight (Value' op) | |
ValueSome (Value' op) | |
ValueNone | |
ValueNil | |
ValueSeq (NonEmpty $ Value' op) | A sequence of elements: can be a list or a set. We can't distinguish lists and sets during parsing. |
ValueMap (NonEmpty $ Elt op) | |
ValueLambda (NonEmpty op) |
Instances
Instances
Functor Elt Source # | |
Eq op => Eq (Elt op) Source # | |
Data op => Data (Elt op) Source # | |
Defined in Michelson.Untyped.Value gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Elt op -> c (Elt op) # gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c (Elt op) # toConstr :: Elt op -> Constr # dataTypeOf :: Elt op -> DataType # dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c (Elt op)) # dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c (Elt op)) # gmapT :: (forall b. Data b => b -> b) -> Elt op -> Elt op # gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Elt op -> r # gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Elt op -> r # gmapQ :: (forall d. Data d => d -> u) -> Elt op -> [u] # gmapQi :: Int -> (forall d. Data d => d -> u) -> Elt op -> u # gmapM :: Monad m => (forall d. Data d => d -> m d) -> Elt op -> m (Elt op) # gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Elt op -> m (Elt op) # gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Elt op -> m (Elt op) # | |
Show op => Show (Elt op) Source # | |
Generic (Elt op) Source # | |
Arbitrary op => Arbitrary (Elt op) Source # | |
ToJSON op => ToJSON (Elt op) Source # | |
Defined in Michelson.Untyped.Value | |
FromJSON op => FromJSON (Elt op) Source # | |
RenderDoc op => Buildable (Elt op) Source # | |
Defined in Michelson.Untyped.Value | |
(Arbitrary op, ToADTArbitrary op) => ToADTArbitrary (Elt op) Source # | |
Defined in Util.Test.Arbitrary toADTArbitrarySingleton :: Proxy (Elt op) -> Gen (ADTArbitrarySingleton (Elt op)) # toADTArbitrary :: Proxy (Elt op) -> Gen (ADTArbitrary (Elt op)) # | |
RenderDoc op => RenderDoc (Elt op) Source # | |
Defined in Michelson.Untyped.Value | |
type Rep (Elt op) Source # | |
Defined in Michelson.Untyped.Value type Rep (Elt op) = D1 (MetaData "Elt" "Michelson.Untyped.Value" "morley-1.0.0-Jo9z4xumEmKBIsSgg9Z0MH" False) (C1 (MetaCons "Elt" PrefixI False) (S1 (MetaSel (Nothing :: Maybe Symbol) NoSourceUnpackedness NoSourceStrictness DecidedStrict) (Rec0 (Value' op)) :*: S1 (MetaSel (Nothing :: Maybe Symbol) NoSourceUnpackedness NoSourceStrictness DecidedStrict) (Rec0 (Value' op)))) |
newtype InternalByteString Source #
ByteString does not have an instance for ToJSON and FromJSON, to avoid orphan type class instances, make a new type wrapper around it.