aboutsummaryrefslogtreecommitdiff
path: root/src/dotty/tools/dotc/typer/Checking.scala
diff options
context:
space:
mode:
authorMartin Odersky <odersky@gmail.com>2016-07-13 15:17:17 +0200
committerMartin Odersky <odersky@gmail.com>2016-07-13 15:33:47 +0200
commit18b30803952cee83580eab28068bc773fdce780e (patch)
tree03c603f0920da2b987d9b93b5b820c099f9049e5 /src/dotty/tools/dotc/typer/Checking.scala
parent0ff5354e2a5e3f29234d6d761177f9228d8da522 (diff)
downloaddotty-18b30803952cee83580eab28068bc773fdce780e.tar.gz
dotty-18b30803952cee83580eab28068bc773fdce780e.tar.bz2
dotty-18b30803952cee83580eab28068bc773fdce780e.zip
Allow hk parameters in lower bounds
Diffstat (limited to 'src/dotty/tools/dotc/typer/Checking.scala')
-rw-r--r--src/dotty/tools/dotc/typer/Checking.scala12
1 files changed, 0 insertions, 12 deletions
diff --git a/src/dotty/tools/dotc/typer/Checking.scala b/src/dotty/tools/dotc/typer/Checking.scala
index b37216e6e..9e55216c1 100644
--- a/src/dotty/tools/dotc/typer/Checking.scala
+++ b/src/dotty/tools/dotc/typer/Checking.scala
@@ -534,17 +534,6 @@ trait Checking {
errorTree(tpt, d"missing type parameter for ${tpt.tpe}")
}
else tpt
-
- def checkLowerNotHK(sym: Symbol, tparams: List[Symbol], pos: Position)(implicit ctx: Context) =
- if (tparams.nonEmpty)
- sym.info match {
- case info: TypeAlias => // ok
- case TypeBounds(lo, _) =>
- for (tparam <- tparams)
- if (tparam.typeRef.occursIn(lo))
- ctx.error(i"type parameter ${tparam.name} may not occur in lower bound $lo", pos)
- case _ =>
- }
}
trait NoChecking extends Checking {
@@ -558,5 +547,4 @@ trait NoChecking extends Checking {
override def checkNoDoubleDefs(cls: Symbol)(implicit ctx: Context): Unit = ()
override def checkParentCall(call: Tree, caller: ClassSymbol)(implicit ctx: Context) = ()
override def checkSimpleKinded(tpt: Tree)(implicit ctx: Context): Tree = tpt
- override def checkLowerNotHK(sym: Symbol, tparams: List[Symbol], pos: Position)(implicit ctx: Context) = ()
}