java.lang.Object
java.lang.Record
org.aya.resolve.ResolveInfo
- Record Components:
primFactory- (global) all primitives shared among all modules in a compilation task.shapeFactory- (scoped per file/ResolveInfo)CodeShapethat are discovered during tycking this module, modified by tycker.opSet- (scoped per file/ResolveInfo) binary operators.opRename- rename-as-operators, only stores names that renamed in current module (and re-exported ops).imports- modules imported using `import` command.reExports- modules re-exported using `public open` command.depGraph- dependency graph of definitions. for each (v, successors) in the graph, `successors` should be tycked first.
public record ResolveInfo(@NotNull ModuleContext thisModule, @NotNull kala.collection.immutable.ImmutableSeq<Stmt> program, PrimDef.Factory primFactory, AyaShape.Factory shapeFactory, @NotNull AyaBinOpSet opSet, @NotNull kala.collection.mutable.MutableMap<DefVar<?,?>,kala.tuple.Tuple3<ResolveInfo.RenamedOpDecl,BindBlock,Boolean>> opRename, @NotNull kala.collection.mutable.MutableMap<kala.collection.immutable.ImmutableSeq<String>,ResolveInfo> imports, @NotNull kala.collection.mutable.MutableMap<kala.collection.immutable.ImmutableSeq<String>,UseHide> reExports, @NotNull org.aya.util.terck.MutableGraph<TyckOrder> depGraph)
extends Record
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionResolveInfo(PrimDef.Factory primFactory, AyaShape.Factory shapeFactory, @NotNull AyaBinOpSet opSet, @NotNull ModuleContext thisModule, @NotNull kala.collection.immutable.ImmutableSeq<Stmt> thisProgram) ResolveInfo(PrimDef.Factory primFactory, @NotNull ModuleContext thisModule, @NotNull kala.collection.immutable.ImmutableSeq<Stmt> thisProgram) ResolveInfo(@NotNull ModuleContext thisModule, @NotNull kala.collection.immutable.ImmutableSeq<Stmt> program, PrimDef.Factory primFactory, AyaShape.Factory shapeFactory, @NotNull AyaBinOpSet opSet, @NotNull kala.collection.mutable.MutableMap<DefVar<?, ?>, kala.tuple.Tuple3<ResolveInfo.RenamedOpDecl, BindBlock, Boolean>> opRename, @NotNull kala.collection.mutable.MutableMap<kala.collection.immutable.ImmutableSeq<String>, ResolveInfo> imports, @NotNull kala.collection.mutable.MutableMap<kala.collection.immutable.ImmutableSeq<String>, UseHide> reExports, @NotNull org.aya.util.terck.MutableGraph<TyckOrder> depGraph) Creates an instance of aResolveInforecord class. -
Method Summary
Modifier and TypeMethodDescription@NotNull org.aya.util.terck.MutableGraph<TyckOrder>depGraph()Returns the value of thedepGraphrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.@NotNull kala.collection.mutable.MutableMap<kala.collection.immutable.ImmutableSeq<String>,ResolveInfo> imports()Returns the value of theimportsrecord component.@NotNull ExprTyckernewTycker(@NotNull org.aya.util.reporter.Reporter reporter, @Nullable Trace.Builder builder) voidopen(@NotNull ResolveInfo other, @NotNull org.aya.util.error.SourcePos sourcePos, Stmt.Accessibility acc) @NotNull kala.collection.mutable.MutableMap<DefVar<?,?>, kala.tuple.Tuple3<ResolveInfo.RenamedOpDecl, BindBlock, Boolean>> opRename()Returns the value of theopRenamerecord component.@NotNull AyaBinOpSetopSet()Returns the value of theopSetrecord component.Returns the value of theprimFactoryrecord component.@NotNull kala.collection.immutable.ImmutableSeq<Stmt>program()Returns the value of theprogramrecord component.Returns the value of thereExportsrecord component.voidrenameOp(@NotNull DefVar<?, ?> defVar, @NotNull ResolveInfo.RenamedOpDecl renamed, @NotNull BindBlock bind, boolean definedHere) Returns the value of theshapeFactoryrecord component.@NotNull ModuleContextReturns the value of thethisModulerecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
ResolveInfo
public ResolveInfo(@NotNull PrimDef.Factory primFactory, @NotNull AyaShape.Factory shapeFactory, @NotNull @NotNull AyaBinOpSet opSet, @NotNull @NotNull ModuleContext thisModule, @NotNull @NotNull kala.collection.immutable.ImmutableSeq<Stmt> thisProgram) -
ResolveInfo
public ResolveInfo(@NotNull PrimDef.Factory primFactory, @NotNull @NotNull ModuleContext thisModule, @NotNull @NotNull kala.collection.immutable.ImmutableSeq<Stmt> thisProgram) -
ResolveInfo
public ResolveInfo(@NotNull @NotNull ModuleContext thisModule, @NotNull @NotNull kala.collection.immutable.ImmutableSeq<Stmt> program, @NotNull PrimDef.Factory primFactory, @NotNull AyaShape.Factory shapeFactory, @NotNull @NotNull AyaBinOpSet opSet, @NotNull @NotNull kala.collection.mutable.MutableMap<DefVar<?, ?>, kala.tuple.Tuple3<ResolveInfo.RenamedOpDecl, BindBlock, Boolean>> opRename, @NotNull @NotNull kala.collection.mutable.MutableMap<kala.collection.immutable.ImmutableSeq<String>, ResolveInfo> imports, @NotNull @NotNull kala.collection.mutable.MutableMap<kala.collection.immutable.ImmutableSeq<String>, UseHide> reExports, @NotNull @NotNull org.aya.util.terck.MutableGraph<TyckOrder> depGraph) Creates an instance of aResolveInforecord class.- Parameters:
thisModule- the value for thethisModulerecord componentprogram- the value for theprogramrecord componentprimFactory- the value for theprimFactoryrecord componentshapeFactory- the value for theshapeFactoryrecord componentopSet- the value for theopSetrecord componentopRename- the value for theopRenamerecord componentimports- the value for theimportsrecord componentreExports- the value for thereExportsrecord componentdepGraph- the value for thedepGraphrecord component
-
-
Method Details
-
renameOp
public void renameOp(@NotNull @NotNull DefVar<?, ?> defVar, @NotNull @NotNull ResolveInfo.RenamedOpDecl renamed, @NotNull @NotNull BindBlock bind, boolean definedHere) - Parameters:
definedHere- Is this operator renamed in this module, or publicly renamed by upstream?- See Also:
-
open
public void open(@NotNull @NotNull ResolveInfo other, @NotNull @NotNull org.aya.util.error.SourcePos sourcePos, @NotNull Stmt.Accessibility acc) -
newTycker
@NotNull public @NotNull ExprTycker newTycker(@NotNull @NotNull org.aya.util.reporter.Reporter reporter, @Nullable Trace.Builder builder) -
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. -
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. -
equals
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 withObjects::equals(Object,Object). -
thisModule
Returns the value of thethisModulerecord component.- Returns:
- the value of the
thisModulerecord component
-
program
Returns the value of theprogramrecord component.- Returns:
- the value of the
programrecord component
-
primFactory
Returns the value of theprimFactoryrecord component.- Returns:
- the value of the
primFactoryrecord component
-
shapeFactory
Returns the value of theshapeFactoryrecord component.- Returns:
- the value of the
shapeFactoryrecord component
-
opSet
Returns the value of theopSetrecord component.- Returns:
- the value of the
opSetrecord component
-
opRename
@NotNull public @NotNull kala.collection.mutable.MutableMap<DefVar<?,?>, opRename()kala.tuple.Tuple3<ResolveInfo.RenamedOpDecl, BindBlock, Boolean>> Returns the value of theopRenamerecord component.- Returns:
- the value of the
opRenamerecord component
-
imports
@NotNull public @NotNull kala.collection.mutable.MutableMap<kala.collection.immutable.ImmutableSeq<String>,ResolveInfo> imports()Returns the value of theimportsrecord component.- Returns:
- the value of the
importsrecord component
-
reExports
@NotNull public @NotNull kala.collection.mutable.MutableMap<kala.collection.immutable.ImmutableSeq<String>,UseHide> reExports()Returns the value of thereExportsrecord component.- Returns:
- the value of the
reExportsrecord component
-
depGraph
Returns the value of thedepGraphrecord component.- Returns:
- the value of the
depGraphrecord component
-