object Terms
- Alphabetic
- By Inheritance
- Terms
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Type Members
-
case class
Apply(func: Value[SType], args: IndexedSeq[Value[SType]]) extends Value[SType] with Product with Serializable
ErgoTree node which represents application of function
func
to the given arguments.ErgoTree node which represents application of function
func
to the given arguments.- func
expression which evaluates to a function
- args
arguments of the function application
-
case class
ApplyTypes(input: Value[SType], tpeArgs: Seq[SType]) extends Value[SType] with Product with Serializable
Apply types for type parameters of input value.
-
case class
Block(bindings: Seq[Val], result: SValue) extends Value[SType] with Product with Serializable
Frontend representation of a block of Val definitions.
Frontend representation of a block of Val definitions. { val x = ...; val y = ... } This node is not part of ErgoTree and hence have Undefined opCode.
-
case class
Ident(name: String, tpe: SType = NoType) extends Value[SType] with Product with Serializable
Frontend node to represent variable names parsed in a source code.
Frontend node to represent variable names parsed in a source code. Should be resolved during compilation to lambda argument, Val definition or compilation environment value.
-
case class
Lambda(tpeParams: Seq[STypeParam], args: IndexedSeq[(String, SType)], givenResType: SType, body: Option[Value[SType]]) extends Value[SFunc] with Product with Serializable
Frontend implementation of lambdas.
Frontend implementation of lambdas. Should be transformed to FuncValue.
-
case class
MethodCall(obj: Value[SType], method: SMethod, args: IndexedSeq[Value[SType]], typeSubst: Map[STypeVar, SType]) extends Value[SType] with Product with Serializable
Represents in ErgoTree an invocation of method of the object
obj
with argumentsargs
.Represents in ErgoTree an invocation of method of the object
obj
with argumentsargs
. The SMethod instances in STypeCompanions may have type STypeIdent in methods types, but valid ErgoTree should have SMethod instances specialized for specific types of obj and args usingspecializeFor
. This means, if we save typeId, methodId, and we save all the arguments, we can restore the specialized SMethod instance. This work by induction, if we assume all arguments are monomorphic, then we can make MethodCall monomorphic. Thus, all ErgoTree instances are monomorphic by construction.- obj
object on which method will be invoked
- method
method to be invoked
- args
arguments passed to the method on invocation
- typeSubst
a map of concrete type for each generic type parameter
-
case class
MethodCallLike(obj: Value[SType], name: String, args: IndexedSeq[Value[SType]], tpe: SType = NoType) extends Value[SType] with Product with Serializable
Frontend node to represent potential method call in a source code.
Frontend node to represent potential method call in a source code. Should be resolved during compilation to MethodCall. Cannot be serialized to ErgoTree.
-
case class
OperationId(name: String, opType: SFunc) extends Product with Serializable
Operation identity descriptor used in AOT costing (see usages in RuntimeCosting and CostTable)
- case class STypeParam(ident: STypeVar, upperBound: Option[SType] = None, lowerBound: Option[SType] = None) extends Product with Serializable
-
type
STypeSubst = Map[STypeVar, SType]
Type alias for a substitution of type variables with their corresponding types.
-
case class
Select(obj: Value[SType], field: String, resType: Option[SType] = None) extends Value[SType] with Product with Serializable
Frontend node to select a field from an object.
Frontend node to select a field from an object. Should be transformed to SelectField
- trait Val extends Value[SType]
- case class ValNode(name: String, givenType: SType, body: SValue) extends Value[SType] with Val with Product with Serializable
- implicit final class ValueOps extends AnyVal
-
case class
ZKProofBlock(body: SigmaPropValue) extends BoolValue with Product with Serializable
IR node to represent explicit Zero Knowledge scope in ErgoTree.
IR node to represent explicit Zero Knowledge scope in ErgoTree. Compiler checks Zero Knowledge properties and issue error message is case of violations. ZK-scoping is optional, it can be used when the user want to ensure Zero Knowledge of specific set of operations. Usually it will require simple restructuring of the code to make the scope body explicit. Invariants checked by the compiler:
- single ZKProof in ErgoTree in a root position
- no boolean operations in the body, because otherwise the result may be disclosed
- all the operations are over SigmaProp values
For motivation and details see https://github.com/ScorexFoundation/sigmastate-interpreter/issues/236
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
val
EmptySubst: Map[STypeVar, SType]
Immutable and sharable empty substitution.
-
def
applySubst(tpe: SType, subst: STypeSubst): SType
Applies a type substitution to a given type.
Applies a type substitution to a given type.
- tpe
the type to apply the substitution to
- subst
the type substitution to apply
- returns
the type after applying the substitution
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
finalize(): Unit
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
def
msgType(t1: SType, t2: SType): Option[SType]
Computes the most general type given two types.
Computes the most general type given two types.
- t1
the first type
- t2
the second type
- returns
the most general type if it exists, otherwise None
-
def
msgTypeOf(ts: Seq[SType]): Option[SType]
Most Specific Generalized (MSG) type of ts.
Most Specific Generalized (MSG) type of ts. Currently just the type of the first element as long as all the elements have the same type.
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
def
unifyTypeLists(items1: Seq[SType], items2: Seq[SType]): Option[STypeSubst]
Performs pairwise type unification making sure each type variable is equally substituted in all items.
-
def
unifyTypes(t1: SType, t2: SType): Option[STypeSubst]
Finds a substitution
subst
of type variables such that unifyTypes(applySubst(t1, subst), t2) shouldBe Some(emptySubst) -
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
- object Apply extends FixedCostValueCompanion with Serializable
- object ApplyTypes extends ValueCompanion with Serializable
- object Block extends ValueCompanion with Serializable
- object Ident extends ValueCompanion with Serializable
- object Lambda extends ValueCompanion with Serializable
- object MethodCall extends FixedCostValueCompanion with Serializable
- object MethodCallLike extends ValueCompanion with Serializable
- object PropertyCall extends FixedCostValueCompanion
- object STypeParam extends Serializable
- object Select extends ValueCompanion with Serializable
- object Val
- object ValNode extends ValueCompanion with Serializable
- object ZKProofBlock extends ValueCompanion with Serializable