Module aya.base

Interface Term

All Superinterfaces:
AyaDocile, org.aya.guest0x0.cubical.Restr.TermLike<Term>
All Known Subinterfaces:
Callable, Callable.DefCall, Elimination, StableWHNF
All Known Implementing Classes:
AppTerm, CoeTerm, ConCall, DataCall, ErrorTerm, FieldTerm, FnCall, FormulaTerm, HCompTerm, IntegerTerm, IntervalTerm, LamTerm, ListTerm, MatchTerm, MetaLitTerm, MetaPatTerm, MetaTerm, NewTerm, PAppTerm, PartialTerm, PartialTyTerm, PathTerm, PiTerm, PLamTerm, PrimCall, ProjTerm, RefTerm, RefTerm.Field, SigmaTerm, SortTerm, StringTerm, StructCall, TupTerm

public sealed interface Term extends AyaDocile, org.aya.guest0x0.cubical.Restr.TermLike<Term> permits Callable, CoeTerm, Elimination, FormulaTerm, HCompTerm, IntervalTerm, MatchTerm, MetaLitTerm, MetaPatTerm, PartialTerm, PiTerm, RefTerm, RefTerm.Field, SigmaTerm, StableWHNF
A well-typed and terminating term.
  • Method Details

    • descent

      @NotNull default @NotNull Term descent(@NotNull @NotNull UnaryOperator<@NotNull Term> f)
    • subst

      @NotNull default @NotNull Term subst(@NotNull @NotNull AnyVar var, @NotNull @NotNull Term term)
    • subst

      @NotNull default @NotNull Term subst(@NotNull @NotNull Subst subst)
    • subst

      @NotNull default @NotNull Term subst(@NotNull @NotNull kala.collection.Map<AnyVar,? extends Term> subst)
    • subst

      @NotNull default @NotNull Term subst(@NotNull @NotNull Subst subst, int ulift)
    • rename

      @NotNull default @NotNull Term rename()
    • findUsages

      default int findUsages(@NotNull @NotNull AnyVar var)
    • scopeCheck

      default VarConsumer.ScopeChecker scopeCheck(@NotNull @NotNull kala.collection.immutable.ImmutableSeq<LocalVar> allowed)
    • normalize

      @NotNull default @NotNull Term normalize(@NotNull @NotNull TyckState state, @NotNull @NotNull NormalizeMode mode)
      Parameters:
      state - used for inlining the holes. Can be null only if we're absolutely sure that holes are frozen, like in the error messages.
    • freezeHoles

      @NotNull default @NotNull Term freezeHoles(@Nullable @Nullable TyckState state)
    • toDoc

      @NotNull default @NotNull org.aya.pretty.doc.Doc toDoc(@NotNull @NotNull org.aya.util.distill.DistillerOptions options)
      Specified by:
      toDoc in interface AyaDocile
    • lift

      @NotNull default @NotNull Term lift(int ulift)
    • computeType

      @NotNull default @NotNull Term computeType(@NotNull @NotNull TyckState state, @NotNull @NotNull LocalCtx ctx)
    • computeSort

      @NotNull default @NotNull SortTerm computeSort(@NotNull @NotNull TyckState state, @NotNull @NotNull LocalCtx ctx)