@@ -761,18 +761,24 @@ representation dependency on itself.
761
761
always possible to find a non-inline type which is the ultimate
762
762
representation type of any given inline type.*
763
763
764
+ The * inline erasure* of an inline type ` V ` is obtained by recursively
765
+ replacing every subterm of ` V ` which is an inline type by the
766
+ corresponding representation type.
767
+
768
+ * Note that this inline erasure exists, because it is a compile-time
769
+ error to have a dependency cycle among inline types.*
770
+
764
771
Let
765
772
<code >X<sub >1</sub > extends B<sub >1</sub >, .. X<sub >s</sub > extends B<sub >s</sub ></code >
766
773
be a declaration of the type parameters of a generic entity (* it could
767
774
be a generic class, inline or not, or mixin, or typedef, or function* ).
768
- Let <code >BB<sub >j</sub ></code > be the result of recursively
769
- replacing every inline type that occurs in <code >B<sub >j</sub ></code >,
770
- for _ j_ in _ 1 .. s_ .
775
+ Let <code >BB<sub >j</sub ></code > be the inline erasure of
776
+ <code >B<sub >j</sub ></code >, for _ j_ in _ 1 .. s_ .
771
777
It is a compile-time error if
772
778
<code >X<sub >1</sub > extends BB<sub >1</sub >, .. X<sub >s</sub > extends BB<sub >s</sub ></code >
773
779
has any compile-time errors.
774
780
775
- * For example, this erasure step could map
781
+ * For example, the inline erasure could map
776
782
<code >X extends C<Y >, Y extends X</code > to
777
783
<code >X extends Y, Y extends X</code >,
778
784
which is an error.*
0 commit comments