aboutsummaryrefslogtreecommitdiff
path: root/src/dotty/tools/dotc
diff options
context:
space:
mode:
authorMartin Odersky <odersky@gmail.com>2014-06-26 13:17:24 +0200
committerMartin Odersky <odersky@gmail.com>2014-06-26 13:17:24 +0200
commitf823e422478232aa083f3510fa8ce4914ec99d53 (patch)
tree0c353efa00c894494b8fb1ba6abc02105eab2e1b /src/dotty/tools/dotc
parentc1721485725bb1050730beb2055700d5fa17c4dd (diff)
downloaddotty-f823e422478232aa083f3510fa8ce4914ec99d53.tar.gz
dotty-f823e422478232aa083f3510fa8ce4914ec99d53.tar.bz2
dotty-f823e422478232aa083f3510fa8ce4914ec99d53.zip
Bring LambdaClass inline with its doc comment.
Avoid special treating TermRef, as this is not demanded by the comment and does not change any of the test outcomes.
Diffstat (limited to 'src/dotty/tools/dotc')
-rw-r--r--src/dotty/tools/dotc/core/TypeApplications.scala7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/dotty/tools/dotc/core/TypeApplications.scala b/src/dotty/tools/dotc/core/TypeApplications.scala
index 3452a499b..359be171d 100644
--- a/src/dotty/tools/dotc/core/TypeApplications.scala
+++ b/src/dotty/tools/dotc/core/TypeApplications.scala
@@ -48,8 +48,8 @@ class TypeApplications(val self: Type) extends AnyVal {
* For a typeref referring to a class, the type parameters of the class.
* For a typeref referring to an alias or abstract type, the type parameters of
* its right hand side or upper bound.
- * For a refinement type, the type parameters of its parent, unless there's a
- * refinement with the same name.
+ * For a refinement type, the type parameters of its parent, unless the refinement
+ * re-binds the type parameter with a type-alias.
* For any other non-singleton type proxy, the type parameters of its underlying type.
* For any other type, the empty list.
*/
@@ -105,6 +105,7 @@ class TypeApplications(val self: Type) extends AnyVal {
/** If type `tp` is equal, aliased-to, or upperbounded-by a type of the form
* `LambdaXYZ { ... }`, the class symbol of that type, otherwise NoSymbol.
+ * symbol of that type, otherwise NoSymbol.
* @param forcing if set, might force completion. If not, never forces
* but returns NoSymbol when it would have to otherwise.
*/
@@ -114,8 +115,6 @@ class TypeApplications(val self: Type) extends AnyVal {
if (sym.isLambdaTrait) sym
else if (sym.isClass || sym.isCompleting && !forcing) NoSymbol
else self.info.LambdaClass(forcing)
- case self: TermRef =>
- NoSymbol
case self: TypeProxy =>
self.underlying.LambdaClass(forcing)
case _ =>