Attributes
- Companion
- object
- Source
- ImmutableContext.scala
- Graph
-
- Supertypes
Members list
Value members
Concrete methods
Adds an element to the context.
Adds an element to the context.
If this is not a valid addition, then an exception is thrown.
Attributes
- Definition Classes
- Source
- ImmutableContext.scala
Converts this context into an immutable context.
Converts this context into an immutable context.
Attributes
- Returns
-
A new immutable context that equals this context at the time of calling this method.
- Source
- ImmutableContext.scala
Inherited methods
Applies several updates to the context.
Applies several updates to the context.
Value parameters
- updates
-
The updates to be applied to the context.
Attributes
- Returns
-
An immutable context obtained by applying iteratively applying the updates from left to right.
- Inherited from:
- Context
- Source
- Context.scala
Checks an object with respect to this context.
Checks an object with respect to this context.
This method checks whether a given object is correctly constructed according to this context. For example for a type to check against a context the base types occurring in that type must all be declared in the context.
Type parameters
- T
-
The type of object to be checked.
Value parameters
- t
-
The object to be checked.
Attributes
- Inherited from:
- Context
- Source
- Context.scala
Retrieves all expression-level conditional reduction rules.
Retrieves all expression-level conditional reduction rules.
Attributes
- Returns
-
Returns all the expression-level conditional reduction rules currently stored in this context.
- Inherited from:
- Context
- Source
- Context.scala
Retrieves constants by name and type parameters.
Retrieves constants by name and type parameters.
Value parameters
- name
-
The name for which a constant is to be looked up.
- params
-
The type parameters for which a constant is to be looked up.
Attributes
- Returns
-
Returns
Some ( c )if the context currently contains a constantcwith namenameand type parametersparams. OtherwiseNoneis returned. - Inherited from:
- Context
- Source
- Context.scala
Retrieves constants by name.
Retrieves constants by name.
Value parameters
- name
-
The name for which a constant is to be looked up.
Attributes
- Returns
-
Returns
Some( c )wherec.nameequalsnameif the context currently contains such a constantc, otherwiseNoneis retured. - Inherited from:
- Context
- Source
- Context.scala
Retrieves all the constants defined in this context.
Retrieves all the constants defined in this context.
Attributes
- Returns
-
A list of all the constants that are currently defined in this context.
- Inherited from:
- Context
- Source
- Context.scala
Checks whether the context contains a given definition.
Checks whether the context contains a given definition.
Value parameters
- defn
-
The definition that is to be checked.
Attributes
- Returns
-
Returns
trueif the given definition is an instance of a definition stored in this context. - Inherited from:
- Context
- Source
- Context.scala
Attributes
- Inherited from:
- Context
- Source
- Context.scala
Looks up the definition of a constant.
Looks up the definition of a constant.
Value parameters
- c
-
The constant with type arguments
argswhose definition is to be looked up.
Attributes
- Returns
-
If the constant
chas a definition, thenSome( definition )is returned wheredefinitionis obtained from the definition ofcby instantiating the type variables according to args. - Inherited from:
- Context
- Source
- Context.scala
Retrieves all the definitions of this context.
Retrieves all the definitions of this context.
Attributes
- Returns
-
The current definitions saved by this context i.e. a map associating constants with expressions.
- Inherited from:
- Context
- Source
- Context.scala
Retrieves a facet of this context.
Retrieves a facet of this context.
Type parameters
- T
-
The facet's type.
Attributes
- Returns
-
Returns the facet associated with the given type. If this facet is not present yet, it is initialized and its initial value is returned.
- Inherited from:
- Context
- Source
- Context.scala
Looks up inductive type constructors for a given base type.
Looks up inductive type constructors for a given base type.
Value parameters
- ty
-
The base type whose type constructors are to be looked up.
Attributes
- Returns
-
Returns
Some( ctrs )iftyis an inductive type having constructorsctrs, otherwiseNoneis returned. - Inherited from:
- Context
- Source
- Context.scala
Retrieves inductive type constructors for a given type.
Retrieves inductive type constructors for a given type.
Value parameters
- ty
-
The type whose inductive type constructors are to be looked up.
Attributes
- Returns
-
Returns
Some( ctrs )iftyis an inductive type having constructorsctrs, otherwiseNoneis returned. - Inherited from:
- Context
- Source
- Context.scala
Checks if two expressions normalize to the same expression.
Checks if two expressions normalize to the same expression.
Value parameters
- a
-
An expression to be checked.
- b
-
An expression to be checked.
Attributes
- Returns
-
Returns
trueif and only ifaandbnormalize to the same expression in this context. - Inherited from:
- Context
- Source
- Context.scala
Checks whether the given base type is defined in this context.
Checks whether the given base type is defined in this context.
Value parameters
- ty
-
The base type that is to be checked.
Attributes
- Returns
-
trueiftyis defined in this context,falseotherwise. - Inherited from:
- Context
- Source
- Context.scala
Retrieves all the names declared in this context.
Retrieves all the names declared in this context.
Attributes
- Returns
-
All the names currently declared in this context.
- Inherited from:
- Context
- Source
- Context.scala
Converts this context into a mutable context.
Converts this context into a mutable context.
Attributes
- Returns
-
A new mutable context that equals this context at the time of calling this method.
- Inherited from:
- Context
- Source
- Context.scala
Creates a new name generator for this context.
Creates a new name generator for this context.
Attributes
- Returns
-
A new name generator that avoids all the names currently defined in the context.
- Inherited from:
- Context
- Source
- Context.scala
Normalizes an expression.
Normalizes an expression.
Value parameters
- expression
-
The expression to be normalized.
Attributes
- Returns
-
An expression obtained by normalizing
expressionaccording to the reduction rules currently stored in this context. - Inherited from:
- Context
- Source
- Context.scala
The context's normalizer.
The context's normalizer.
Attributes
- Returns
-
The context's normalizer.
- Inherited from:
- Context
- Source
- Context.scala
Attributes
- Inherited from:
- Context
- Source
- Context.scala
Attributes
- Inherited from:
- Context
- Source
- Context.scala
Retrieves all expression-level reduction rules.
Retrieves all expression-level reduction rules.
Attributes
- Returns
-
Returns all the expression-level reduction rules currently stored in this context.
- Inherited from:
- Context
- Source
- Context.scala
Decides whether the symbol with the given identifier should be a variable or constant, and what its type should be.
Decides whether the symbol with the given identifier should be a variable or constant, and what its type should be.
Value parameters
- s
-
The name of the symbol.
Attributes
- Returns
-
Either IsVar(type) or IsConst(type).
- Inherited from:
- Context
- Source
- Context.scala
Retrieves the skolem definition of a constant.
Retrieves the skolem definition of a constant.
Value parameters
- skSym
-
The constant whose definition is to be looked up.
Attributes
- Returns
-
Returns
Some(definition)if the constantskSymis a skolem function with definitiondefinition. - Inherited from:
- Context
- Source
- Context.scala
Converts this context to a read-only context.
Converts this context to a read-only context.
Attributes
- Returns
-
A new read-only context that is equal to this context at the time of invoking this method.
- Inherited from:
- Context
- Source
- Context.scala
Returns a string representation of the object.
Returns a string representation of the object.
The default representation is platform dependent.
Attributes
- Returns
-
a string representation of the object.
- Definition Classes
-
Context -> Any
- Inherited from:
- Context
- Source
- Context.scala
Reduces an expression to WHNF.
Reduces an expression to WHNF.
Value parameters
- expression
-
The expression to be reduced to WHNF.
Attributes
- Returns
-
An expression reduced to WHNF according to the reduction rules currently stored in this context.
- Inherited from:
- Context
- Source
- Context.scala
Concrete fields
Retrieves the context's current state.
Retrieves the context's current state.
Attributes
- Returns
-
The context's current state.
- Source
- ImmutableContext.scala
Retrieves the updates that have been applied to this context.
Retrieves the updates that have been applied to this context.
Attributes
- Returns
-
A list of updates with newer updates occurring before older ones.
- Source
- ImmutableContext.scala