scalacenter / scala

The Scala programming language

Home Page:http://www.scala-lang.org/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Resolve name of trait within trait

bishabosha opened this issue · comments

When looking for an overloaded method with a signature containing scala[Qualified . reflect][Qualified . api][Qualified . Exprs][Qualified . Expr], we call requiredClass("scala.reflect.api.Exprs.Expr"), which fails because Exprs is not a term. Possible alternatives are to implement requiredClass/Module especially for TastyName, or rethink how we match a method to a Signature[ErasedTypeRef], perhaps we should have an operation Type => ErasedTypeRef, and not the other way around.

look here for inspiration: https://github.com/lampepfl/dotty/blob/91e049d6551728bb1615d2860fc4711b10336749/compiler/src/dotty/tools/dotc/core/TypeErasure.scala#L157