Skip to content

Commit b22dc6d

Browse files
committed
Revert of b2e0e7b "tpd.TreeOps#select creates non member syms after erasure."
With the new more systematic treatment of fresh symbols in TreeTypeMap, this is no longer ncessary.
1 parent 5634dcc commit b22dc6d

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

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

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -522,8 +522,7 @@ object tpd extends Trees.Instance[Type] with TypedTreeInfo {
522522

523523
def select(sym: Symbol)(implicit ctx: Context): Select =
524524
untpd.Select(tree, sym.name).withType(
525-
if (ctx.erasedTypes) TermRef.withFixedSym(tree.tpe, sym.name.asTermName, sym.asTerm)
526-
else TermRef.withSigAndDenot(tree.tpe, sym.name.asTermName, sym.signature, sym.denot.asSeenFrom(tree.tpe)))
525+
TermRef.withSigAndDenot(tree.tpe, sym.name.asTermName, sym.signature, sym.denot.asSeenFrom(tree.tpe)))
527526

528527
def selectWithSig(name: Name, sig: Signature)(implicit ctx: Context) =
529528
untpd.SelectWithSig(tree, name, sig)

0 commit comments

Comments
 (0)