Module aya.base
Package org.aya.tyck

Record Class StmtTycker

java.lang.Object
java.lang.Record
org.aya.tyck.StmtTycker

public record StmtTycker(@NotNull org.aya.util.reporter.Reporter reporter, @Nullable Trace.Builder traceBuilder) extends Record
API Note:
this class does not create ExprTycker instances itself, but use the one passed to it. newTycker(org.aya.core.def.PrimDef.Factory, org.aya.core.repr.AyaShape.Factory) creates instances of expr tyckers.
  • Constructor Details

    • StmtTycker

      public StmtTycker(@NotNull @NotNull org.aya.util.reporter.Reporter reporter, @Nullable Trace.Builder traceBuilder)
      Creates an instance of a StmtTycker record class.
      Parameters:
      reporter - the value for the reporter record component
      traceBuilder - the value for the traceBuilder record component
  • Method Details

    • newTycker

      @NotNull public @NotNull ExprTycker newTycker(@NotNull PrimDef.Factory primFactory, @NotNull AyaShape.Factory literalShapes)
    • tyck

      @NotNull public @NotNull GenericDef tyck(@NotNull @NotNull Decl decl, @NotNull @NotNull ExprTycker tycker)
    • simpleFn

      @NotNull public @NotNull FnDef simpleFn(@NotNull @NotNull ExprTycker tycker, TeleDecl.FnDecl fn)
    • tyckHeader

      public void tyckHeader(@NotNull @NotNull Decl decl, @NotNull @NotNull ExprTycker tycker)
    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • reporter

      @NotNull public @NotNull org.aya.util.reporter.Reporter reporter()
      Returns the value of the reporter record component.
      Returns:
      the value of the reporter record component
    • traceBuilder

      public @Nullable Trace.Builder traceBuilder()
      Returns the value of the traceBuilder record component.
      Returns:
      the value of the traceBuilder record component