diff options
author | Martin Odersky <odersky@gmail.com> | 2014-11-10 10:35:54 +0100 |
---|---|---|
committer | Martin Odersky <odersky@gmail.com> | 2014-11-10 10:35:54 +0100 |
commit | 83734e1962c11b3e699ece5787caf845cbfa6c0d (patch) | |
tree | dfa2fc2d3e7d5547c4d73244df4d60ad06bafda7 /src/dotty/tools/dotc/core/SymDenotations.scala | |
parent | f2e3489e419a104ad5f30db68eeaf035a0f3339b (diff) | |
download | dotty-83734e1962c11b3e699ece5787caf845cbfa6c0d.tar.gz dotty-83734e1962c11b3e699ece5787caf845cbfa6c0d.tar.bz2 dotty-83734e1962c11b3e699ece5787caf845cbfa6c0d.zip |
Generalize symbolic refs
Previously, there was a switch in SymDenotation#termRef to create a WithFixedSym ref
when after erasure. This was done to fix a broken test, but it's clearly incomplete.
The scheme is now replaced by one which always creates WithFixedSym Termrefs after
erasure.
Diffstat (limited to 'src/dotty/tools/dotc/core/SymDenotations.scala')
-rw-r--r-- | src/dotty/tools/dotc/core/SymDenotations.scala | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/dotty/tools/dotc/core/SymDenotations.scala b/src/dotty/tools/dotc/core/SymDenotations.scala index 0d92a8e5f..dfb58f68b 100644 --- a/src/dotty/tools/dotc/core/SymDenotations.scala +++ b/src/dotty/tools/dotc/core/SymDenotations.scala @@ -896,9 +896,8 @@ object SymDenotations { override def valRef(implicit ctx: Context): TermRef = TermRef.withSigAndDenot(owner.thisType, name.asTermName, Signature.NotAMethod, this) - override def termRefWithSig(implicit ctx: Context): TermRef = // TODO generalize - if (ctx.erasedTypes) TermRef.withFixedSym(owner.thisType, name.asTermName, symbol.asTerm) - else TermRef.withSigAndDenot(owner.thisType, name.asTermName, signature, this) + override def termRefWithSig(implicit ctx: Context): TermRef = + TermRef.withSigAndDenot(owner.thisType, name.asTermName, signature, this) def nonMemberTermRef(implicit ctx: Context): TermRef = TermRef.withFixedSym(owner.thisType, name.asTermName, symbol.asTerm) |