Skip to content

Commit 13692aa

Browse files
committed
TypedTreeCopier#Select: don't use unstable prefixes
This manifested itself as a pickling difference in tasty_tools Note that there are probably more issues in this method, in particular the old type is reused when `qualifier.tpe eq tree.qualifier.tpe` even if the `name` is different. But I'm only trying to get the tests to pass for now.
1 parent b9982d8 commit 13692aa

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

compiler/src/dotty/tools/dotc/ast/tpd.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -457,7 +457,7 @@ object tpd extends Trees.Instance[Type] with TypedTreeInfo {
457457
case tree: Select if qualifier.tpe eq tree.qualifier.tpe =>
458458
tree1.withTypeUnchecked(tree.tpe)
459459
case _ => tree.tpe match {
460-
case tpe: NamedType => tree1.withType(tpe.derivedSelect(qualifier.tpe))
460+
case tpe: NamedType => tree1.withType(tpe.derivedSelect(qualifier.tpe.widenIfUnstable))
461461
case _ => tree1.withTypeUnchecked(tree.tpe)
462462
}
463463
}

0 commit comments

Comments
 (0)