plutus-tx-1.30.0.0: Libraries for Plutus Tx and its prelude
Safe HaskellSafe-Inferred
LanguageHaskell2010

PlutusTx.Bool

Synopsis

Documentation

data Bool Source #

Constructors

False 
True 

Instances

Instances details
FromJSON Bool 
Instance details

Defined in Data.Aeson.Types.FromJSON

Methods

parseJSON ∷ Value → Parser Bool

parseJSONList ∷ Value → Parser [Bool]

omittedFieldMaybe Bool

FromJSONKey Bool 
Instance details

Defined in Data.Aeson.Types.FromJSON

Methods

fromJSONKey ∷ FromJSONKeyFunction Bool

fromJSONKeyList ∷ FromJSONKeyFunction [Bool]

ToJSON Bool 
Instance details

Defined in Data.Aeson.Types.ToJSON

Methods

toJSONBool → Value

toEncodingBool → Encoding

toJSONList ∷ [Bool] → Value

toEncodingList ∷ [Bool] → Encoding

omitFieldBoolBool

ToJSONKey Bool 
Instance details

Defined in Data.Aeson.Types.ToJSON

Methods

toJSONKey ∷ ToJSONKeyFunction Bool

toJSONKeyList ∷ ToJSONKeyFunction [Bool]

Data Bool

Since: base-4.0.0.0

Instance details

Defined in Data.Data

Methods

gfoldl ∷ (∀ d b. Data d ⇒ c (d → b) → d → c b) → (∀ g. g → c g) → Bool → c Bool Source #

gunfold ∷ (∀ b r. Data b ⇒ c (b → r) → c r) → (∀ r. r → c r) → Constr → c Bool Source #

toConstrBoolConstr Source #

dataTypeOfBoolDataType Source #

dataCast1Typeable t ⇒ (∀ d. Data d ⇒ c (t d)) → Maybe (c Bool) Source #

dataCast2Typeable t ⇒ (∀ d e. (Data d, Data e) ⇒ c (t d e)) → Maybe (c Bool) Source #

gmapT ∷ (∀ b. Data b ⇒ b → b) → BoolBool Source #

gmapQl ∷ (r → r' → r) → r → (∀ d. Data d ⇒ d → r') → Bool → r Source #

gmapQr ∷ ∀ r r'. (r' → r → r) → r → (∀ d. Data d ⇒ d → r') → Bool → r Source #

gmapQ ∷ (∀ d. Data d ⇒ d → u) → Bool → [u] Source #

gmapQiInt → (∀ d. Data d ⇒ d → u) → Bool → u Source #

gmapMMonad m ⇒ (∀ d. Data d ⇒ d → m d) → Bool → m Bool Source #

gmapMpMonadPlus m ⇒ (∀ d. Data d ⇒ d → m d) → Bool → m Bool Source #

gmapMoMonadPlus m ⇒ (∀ d. Data d ⇒ d → m d) → Bool → m Bool Source #

Bounded Bool

Since: base-2.1

Instance details

Defined in GHC.Enum

Enum Bool

Since: base-2.1

Instance details

Defined in GHC.Enum

Generic Bool 
Instance details

Defined in GHC.Generics

Associated Types

type Rep BoolTypeType Source #

Methods

fromBoolRep Bool x Source #

toRep Bool x → Bool Source #

SingKind Bool

Since: base-4.9.0.0

Instance details

Defined in GHC.Generics

Associated Types

type DemoteRep Bool

Methods

fromSing ∷ ∀ (a ∷ Bool). Sing a → DemoteRep Bool

Ix Bool

Since: base-2.1

Instance details

Defined in GHC.Ix

Methods

range ∷ (Bool, Bool) → [Bool] Source #

index ∷ (Bool, Bool) → BoolInt Source #

unsafeIndex ∷ (Bool, Bool) → BoolInt Source #

inRange ∷ (Bool, Bool) → BoolBool Source #

rangeSize ∷ (Bool, Bool) → Int Source #

unsafeRangeSize ∷ (Bool, Bool) → Int Source #

Read Bool

Since: base-2.1

Instance details

Defined in GHC.Read

Show Bool

Since: base-2.1

Instance details

Defined in GHC.Show

Methods

showsPrecIntBoolShowS Source #

showBoolString Source #

showList ∷ [Bool] → ShowS Source #

BitOps Bool 
Instance details

Defined in Basement.Bits

Methods

(.&.)BoolBoolBool

(.|.)BoolBoolBool

(.^.)BoolBoolBool

(.<<.)Bool → CountOf BoolBool

(.>>.)Bool → CountOf BoolBool

bit ∷ Offset BoolBool

isBitSetBool → Offset BoolBool

setBitBool → Offset BoolBool

clearBitBool → Offset BoolBool

FiniteBitsOps Bool 
Instance details

Defined in Basement.Bits

Methods

numberOfBitsBool → CountOf Bool

rotateLBool → CountOf BoolBool

rotateRBool → CountOf BoolBool

popCountBool → CountOf Bool

bitFlipBoolBool

countLeadingZerosBool → CountOf Bool

countTrailingZerosBool → CountOf Bool

NFData Bool 
Instance details

Defined in Control.DeepSeq

Methods

rnfBool → () Source #

Eq Bool 
Instance details

Defined in GHC.Classes

Methods

(==)BoolBoolBool Source #

(/=)BoolBoolBool Source #

Ord Bool 
Instance details

Defined in GHC.Classes

Methods

compareBoolBoolOrdering Source #

(<)BoolBoolBool Source #

(<=)BoolBoolBool Source #

(>)BoolBoolBool Source #

(>=)BoolBoolBool Source #

maxBoolBoolBool Source #

minBoolBoolBool Source #

Hashable Bool 
Instance details

Defined in Data.Hashable.Class

Methods

hashWithSaltIntBoolInt

hashBoolInt

HasToBuiltin Bool Source # 
Instance details

Defined in PlutusTx.Builtins.HasBuiltin

Associated Types

type ToBuiltin Bool Source #

Enum Bool Source # 
Instance details

Defined in PlutusTx.Enum

Eq Bool Source # 
Instance details

Defined in PlutusTx.Eq

Methods

(==)BoolBoolBool Source #

FromData Bool Source # 
Instance details

Defined in PlutusTx.IsData.Instances

ToData Bool Source # 
Instance details

Defined in PlutusTx.IsData.Instances

UnsafeFromData Bool Source # 
Instance details

Defined in PlutusTx.IsData.Instances

BoundedJoinSemiLattice Bool Source # 
Instance details

Defined in PlutusTx.Lattice

Methods

bottomBool Source #

BoundedMeetSemiLattice Bool Source # 
Instance details

Defined in PlutusTx.Lattice

Methods

topBool Source #

JoinSemiLattice Bool Source # 
Instance details

Defined in PlutusTx.Lattice

Methods

(\/)BoolBoolBool Source #

MeetSemiLattice Bool Source # 
Instance details

Defined in PlutusTx.Lattice

Methods

(/\)BoolBoolBool Source #

AdditiveMonoid Bool Source # 
Instance details

Defined in PlutusTx.Numeric

Methods

zeroBool Source #

AdditiveSemigroup Bool Source # 
Instance details

Defined in PlutusTx.Numeric

Methods

(+)BoolBoolBool Source #

MultiplicativeMonoid Bool Source # 
Instance details

Defined in PlutusTx.Numeric

Methods

oneBool Source #

MultiplicativeSemigroup Bool Source # 
Instance details

Defined in PlutusTx.Numeric

Methods

(*)BoolBoolBool Source #

Ord Bool Source # 
Instance details

Defined in PlutusTx.Ord

Methods

compareBoolBoolOrdering Source #

(<)BoolBoolBool Source #

(<=)BoolBoolBool Source #

(>)BoolBoolBool Source #

(>=)BoolBoolBool Source #

maxBoolBoolBool Source #

minBoolBoolBool Source #

Show Bool Source # 
Instance details

Defined in PlutusTx.Show

Pretty Bool 
Instance details

Defined in Prettyprinter.Internal

Methods

prettyBoolDoc ann #

prettyList ∷ [Bool] → Doc ann #

Uniform Bool 
Instance details

Defined in System.Random.Internal

Methods

uniformM ∷ StatefulGen g m ⇒ g → m Bool

UniformRange Bool 
Instance details

Defined in System.Random.Internal

Methods

uniformRM ∷ StatefulGen g m ⇒ (Bool, Bool) → g → m Bool

Serialise Bool 
Instance details

Defined in Codec.Serialise.Class

Methods

encodeBool → Encoding

decode ∷ Decoder s Bool

encodeList ∷ [Bool] → Encoding

decodeList ∷ Decoder s [Bool]

Unbox Bool 
Instance details

Defined in Data.Vector.Unboxed.Base

Pretty Bool 
Instance details

Defined in Text.PrettyPrint.Annotated.WL

Methods

prettyBool → Doc b

prettyList ∷ [Bool] → Doc b

SingI 'False

Since: base-4.9.0.0

Instance details

Defined in GHC.Generics

Methods

sing ∷ Sing 'False

SingI 'True

Since: base-4.9.0.0

Instance details

Defined in GHC.Generics

Methods

sing ∷ Sing 'True

HasSchema Bool ts Source # 
Instance details

Defined in PlutusTx.Blueprint.Class

Methods

schemaSchema ts Source #

AsDefinitionId Bool Source # 
Instance details

Defined in PlutusTx.Blueprint.Definition.Id

HasFromOpaque BuiltinBool Bool Source # 
Instance details

Defined in PlutusTx.Builtins.HasOpaque

HasToOpaque Bool BuiltinBool Source # 
Instance details

Defined in PlutusTx.Builtins.HasOpaque

Lift DefaultUni Bool Source # 
Instance details

Defined in PlutusTx.Lift.Instances

DefaultPrettyBy config Bool 
Instance details

Defined in Text.PrettyBy.Internal

Methods

defaultPrettyBy ∷ config → BoolDoc ann Source #

defaultPrettyListBy ∷ config → [Bool] → Doc ann Source #

NonDefaultPrettyBy ConstConfig Bool 
Instance details

Defined in PlutusCore.Pretty.PrettyConst

PrettyDefaultBy config BoolPrettyBy config Bool
>>> prettyBy () True
True
Instance details

Defined in Text.PrettyBy.Internal

Methods

prettyBy ∷ config → BoolDoc ann Source #

prettyListBy ∷ config → [Bool] → Doc ann Source #

Lift Bool 
Instance details

Defined in Language.Haskell.TH.Syntax

Methods

liftQuote m ⇒ Bool → m Exp Source #

liftTyped ∷ ∀ (m ∷ TypeType). Quote m ⇒ BoolCode m Bool Source #

Vector Vector Bool 
Instance details

Defined in Data.Vector.Unboxed.Base

Methods

basicUnsafeFreeze ∷ Mutable Vector s BoolST s (Vector Bool)

basicUnsafeThaw ∷ Vector BoolST s (Mutable Vector s Bool)

basicLength ∷ Vector BoolInt

basicUnsafeSliceIntInt → Vector Bool → Vector Bool

basicUnsafeIndexM ∷ Vector BoolInt → Box Bool

basicUnsafeCopy ∷ Mutable Vector s Bool → Vector BoolST s ()

elemseq ∷ Vector BoolBool → b → b

MVector MVector Bool 
Instance details

Defined in Data.Vector.Unboxed.Base

Methods

basicLength ∷ MVector s BoolInt

basicUnsafeSliceIntInt → MVector s Bool → MVector s Bool

basicOverlaps ∷ MVector s Bool → MVector s BoolBool

basicUnsafeNewIntST s (MVector s Bool)

basicInitialize ∷ MVector s BoolST s ()

basicUnsafeReplicateIntBoolST s (MVector s Bool)

basicUnsafeRead ∷ MVector s BoolIntST s Bool

basicUnsafeWrite ∷ MVector s BoolIntBoolST s ()

basicClear ∷ MVector s BoolST s ()

basicSet ∷ MVector s BoolBoolST s ()

basicUnsafeCopy ∷ MVector s Bool → MVector s BoolST s ()

basicUnsafeMove ∷ MVector s Bool → MVector s BoolST s ()

basicUnsafeGrow ∷ MVector s BoolIntST s (MVector s Bool)

KnownBuiltinTypeIn DefaultUni term BoolMakeKnownIn DefaultUni term Bool 
Instance details

Defined in PlutusCore.Default.Universe

Methods

makeKnownBoolBuiltinResult term Source #

KnownBuiltinTypeIn DefaultUni term BoolReadKnownIn DefaultUni term Bool 
Instance details

Defined in PlutusCore.Default.Universe

Methods

readKnown ∷ term → ReadKnownM Bool Source #

Contains DefaultUni Bool 
Instance details

Defined in PlutusCore.Default.Universe

Typeable DefaultUni Bool Source # 
Instance details

Defined in PlutusTx.Lift.Instances

KnownBuiltinTypeAst tyname DefaultUni BoolKnownTypeAst tyname DefaultUni Bool 
Instance details

Defined in PlutusCore.Default.Universe

Associated Types

type IsBuiltin DefaultUni BoolBool Source #

type ToHoles DefaultUni Bool ∷ [Hole] Source #

type ToBinds DefaultUni acc Bool ∷ [Some TyNameRep] Source #

Methods

typeAstType tyname DefaultUni () Source #

type DemoteRep Bool 
Instance details

Defined in GHC.Generics

type DemoteRep Bool = Bool
type Rep Bool

Since: base-4.6.0.0

Instance details

Defined in GHC.Generics

type Rep Bool = D1 ('MetaData "Bool" "GHC.Types" "ghc-prim" 'False) (C1 ('MetaCons "False" 'PrefixI 'False) (U1TypeType) :+: C1 ('MetaCons "True" 'PrefixI 'False) (U1TypeType))
data Sing (a ∷ Bool) 
Instance details

Defined in GHC.Generics

data Sing (a ∷ Bool) where
type ToBuiltin Bool Source # 
Instance details

Defined in PlutusTx.Builtins.HasBuiltin

newtype Vector Bool 
Instance details

Defined in Data.Vector.Unboxed.Base

newtype Vector Bool = V_Bool (Vector Word8)
newtype MVector s Bool 
Instance details

Defined in Data.Vector.Unboxed.Base

newtype MVector s Bool = MV_Bool (MVector s Word8)
type IsBuiltin DefaultUni Bool 
Instance details

Defined in PlutusCore.Default.Universe

type ToHoles DefaultUni Bool 
Instance details

Defined in PlutusCore.Default.Universe

type ToBinds DefaultUni acc Bool 
Instance details

Defined in PlutusCore.Default.Universe

(&&)BoolBoolBool infixr 3 Source #

Logical AND

>>> True && False
False

(||)BoolBoolBool infixr 2 Source #

Logical OR

>>> True || False
True

notBoolBool Source #

Logical negation

>>> not True
False

otherwiseBool Source #

otherwise is defined as the value True. It helps to make guards more readable. eg.

 f x | x < 0     = ...
     | otherwise = ...