diff options
author | Martin Odersky <odersky@gmail.com> | 2013-06-03 11:33:53 +0200 |
---|---|---|
committer | Martin Odersky <odersky@gmail.com> | 2013-06-03 11:33:53 +0200 |
commit | 339809ed82e14699681a5a7765c87133cd681ec0 (patch) | |
tree | 283b653e9260d3feb01e19b955033de74bc53790 /src/dotty/tools/dotc/core/SymDenotations.scala | |
parent | 17d0e7008f62882c10193ea0db09c9b90736c320 (diff) | |
download | dotty-339809ed82e14699681a5a7765c87133cd681ec0.tar.gz dotty-339809ed82e14699681a5a7765c87133cd681ec0.tar.bz2 dotty-339809ed82e14699681a5a7765c87133cd681ec0.zip |
More solid design of Namer with some Typer bits added.
Diffstat (limited to 'src/dotty/tools/dotc/core/SymDenotations.scala')
-rw-r--r-- | src/dotty/tools/dotc/core/SymDenotations.scala | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/src/dotty/tools/dotc/core/SymDenotations.scala b/src/dotty/tools/dotc/core/SymDenotations.scala index 56b168102..e1550d529 100644 --- a/src/dotty/tools/dotc/core/SymDenotations.scala +++ b/src/dotty/tools/dotc/core/SymDenotations.scala @@ -533,17 +533,11 @@ object SymDenotations { * inClass <-- find denot.symbol class C { <-- symbol is here * * site: Subtype of both inClass and C - * */ final def matchingSymbol(inClass: Symbol, site: Type)(implicit ctx: Context): Symbol = { var denot = inClass.info.nonPrivateDecl(name) - if (denot.isTerm) { // types of the same name always match - val targetType = site.memberInfo(symbol) - if (denot.isOverloaded) - denot = denot.atSignature(targetType.signature) // seems we need two kinds of signatures here - if (!(site.memberInfo(denot.symbol) matches targetType)) - denot = NoDenotation - } + if (denot.isTerm) // types of the same name always match + denot = denot.matchingDenotation(site, site.memberInfo(symbol)) denot.symbol } |