Skip to content

Commit ad6b578

Browse files
oderskysmarter
authored andcommitted
Fix problems handling case of bound type var in pickling
1 parent a4d1894 commit ad6b578

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

compiler/src/dotty/tools/dotc/core/tasty/TastyFormat.scala

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -431,7 +431,8 @@ object TastyFormat {
431431
| ANNOTATEDtpt
432432
| ANDtpt
433433
| ORtpt
434-
| BYNAMEtpt => true
434+
| BYNAMEtpt
435+
| BIND => true
435436
case _ => false
436437
}
437438

compiler/src/dotty/tools/dotc/core/tasty/TreeUnpickler.scala

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -249,6 +249,7 @@ class TreeUnpickler(reader: TastyReader, nameAtRef: NameRef => TermName, posUnpi
249249
case BIND =>
250250
val sym = ctx.newSymbol(ctx.owner, readName().toTypeName, BindDefinedType, readType())
251251
registerSym(start, sym)
252+
if (currentAddr != end) readType()
252253
TypeRef.withFixedSym(NoPrefix, sym.name, sym)
253254
case POLYtype =>
254255
readMethodic(PolyType, _.toTypeName)

0 commit comments

Comments
 (0)