diff options
author | Martin Odersky <odersky@gmail.com> | 2014-02-09 18:49:31 +0100 |
---|---|---|
committer | Martin Odersky <odersky@gmail.com> | 2014-02-09 18:49:31 +0100 |
commit | ada0febcb0893ff8f87d01f605a43f731e38a0be (patch) | |
tree | f43c1efa0b743f3e374600d15a7d19a0c74968ed /src/dotty/tools/dotc/typer/Namer.scala | |
parent | 866ee8665147f91bee617465d04a08ff7b874baf (diff) | |
download | dotty-ada0febcb0893ff8f87d01f605a43f731e38a0be.tar.gz dotty-ada0febcb0893ff8f87d01f605a43f731e38a0be.tar.bz2 dotty-ada0febcb0893ff8f87d01f605a43f731e38a0be.zip |
Get rid of CompleteInCreationContext
The only remaining completers that complete in creation context are the source completers defined in Namers. So a separate abstraction is no longer needed.
Diffstat (limited to 'src/dotty/tools/dotc/typer/Namer.scala')
-rw-r--r-- | src/dotty/tools/dotc/typer/Namer.scala | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/dotty/tools/dotc/typer/Namer.scala b/src/dotty/tools/dotc/typer/Namer.scala index 4d184c17b..776d59542 100644 --- a/src/dotty/tools/dotc/typer/Namer.scala +++ b/src/dotty/tools/dotc/typer/Namer.scala @@ -350,7 +350,7 @@ class Namer { typer: Typer => } /** The completer of a symbol defined by a member def or import (except ClassSymbols) */ - class Completer(val original: Tree)(implicit ctx: Context) extends LazyType with CompleteInCreationContext { + class Completer(val original: Tree)(implicit ctx: Context) extends LazyType { protected def localContext(owner: Symbol) = ctx.fresh.withOwner(owner).withTree(original) @@ -376,7 +376,10 @@ class Namer { typer: Typer => } } - override def completeInCreationContext(denot: SymDenotation): Unit = + final override def complete(denot: SymDenotation)(implicit ctx: Context) = + completeInCreationContext(denot) + + def completeInCreationContext(denot: SymDenotation): Unit = denot.info = typeSig(denot.symbol) } |