Skip to content

Commit

Permalink
misc: document
Browse files Browse the repository at this point in the history
  • Loading branch information
HoshinoTented authored and ice1000 committed Nov 15, 2024
1 parent 1527143 commit 3a806d3
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion syntax/src/main/java/org/aya/syntax/core/def/AnyDef.java
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
* v v v v
* ConDef <- - - ConDef.Delegate <----- ConDefLike -----> JitCon
* </pre>
* where the arrows indicate mean "is superclass of".<br/>
* where the arrows mean "is superclass of".<br/>
* <ul>
* <li>The first chain is "core def" chain, which are well-typed definition</li>
* <li>The second chain is "local def" chain, which may refer to a not yet tycked definition, i.e. tyck a recursive function</li>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public sealed interface ClassDefLike extends AnyDef permits JitClass, ClassDef.D

default @NotNull Term telescope(int i, @NotNull Seq<Term> restriction) {
var member = members().get(i);
// Our code should not refer the subterm of self, the only meaningful part is [self.forget()]
// Our code should not refer the subterm of [self], the only meaningful part is [self.forget()]
// Also, we don't use NewTerm, cause the type of the self-parameter is a class call without any restriction.
var self = new ClassCastTerm(this, ErrorTerm.DUMMY, ImmutableSeq.empty(),
restriction.map(Closure::mkConst)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@

public sealed interface MemberDefLike extends AnyDef permits JitMember, MemberDef.Delegate {
@NotNull ClassDefLike classRef();

/**
* The type of the type of this member, not include self-parameter
*/
@NotNull SortTerm type();

int index();
Expand Down

0 comments on commit 3a806d3

Please sign in to comment.