File tree 3 files changed +13
-5
lines changed
compiler/src/dotty/tools/dotc/transform
3 files changed +13
-5
lines changed Original file line number Diff line number Diff line change @@ -9,7 +9,7 @@ import core.Definitions
9
9
import core .Flags ._
10
10
import core .Names .Name
11
11
import core .Symbols ._
12
- import core .TypeApplications .TypeParamInfo
12
+ import core .TypeApplications .{ EtaExpansion , TypeParamInfo }
13
13
import core .TypeErasure .{erasedGlb , erasure , isGenericArrayElement }
14
14
import core .Types ._
15
15
import core .classfile .ClassfileConstants
@@ -166,6 +166,7 @@ object GenericSignatures {
166
166
// a type parameter or similar) must go through here or the signature is
167
167
// likely to end up with Foo<T>.Empty where it needs Foo<T>.Empty$.
168
168
def fullNameInSig (sym : Symbol ): Unit = {
169
+ assert(sym.isClass)
169
170
val name = atPhase(genBCodePhase) { sanitizeName(sym.fullName).replace('.' , '/' ) }
170
171
builder.append('L' ).nn.append(name)
171
172
}
@@ -183,11 +184,10 @@ object GenericSignatures {
183
184
boxedSig(bounds.lo)
184
185
}
185
186
else builder.append('*' )
186
- case PolyType (_, res ) =>
187
- builder.append( '*' ) // scala/bug#7932
187
+ case EtaExpansion (tp ) =>
188
+ argSig(tp)
188
189
case _ : HKTypeLambda =>
189
- fullNameInSig(tp.typeSymbol)
190
- builder.append(';' )
190
+ builder.append('*' )
191
191
case _ =>
192
192
boxedSig(tp.widenDealias.widenNullaryMethod)
193
193
// `tp` might be a singleton type referring to a getter.
Original file line number Diff line number Diff line change 1
1
public Category C.category()
2
2
public Category C.category1()
3
+ public abstract Category<?> M2.category3()
4
+ public abstract Category<java.lang.Object> M2.category2()
3
5
public default Category<F> M1.category()
4
6
public default Category<scala.Tuple2> M1.category1()
5
7
public static Category M1.category$(M1)
6
8
public static Category M1.category1$(M1)
9
+ public abstract Category<?> M2.category3()
10
+ public abstract Category<java.lang.Object> M2.category2()
7
11
public default Category<F> M2.category()
8
12
public default Category<scala.Tuple2> M2.category1()
9
13
public static Category M2.category$(M2)
Original file line number Diff line number Diff line change @@ -13,6 +13,10 @@ trait M1[F] {
13
13
trait M2 [F ] { self : M1 [F ] =>
14
14
override def category : Category [X ] = null
15
15
override def category1 : Category [Tuple2 ] = null
16
+
17
+ type T [A , B ]
18
+ def category2 : Category [T ]
19
+ def category3 : Category [[A , B ] =>> T [B , A ]]
16
20
}
17
21
18
22
abstract class C extends M1 [Float ] with M2 [Float ]
You can’t perform that action at this time.
0 commit comments