aboutsummaryrefslogtreecommitdiff
path: root/src/dotty/tools/dotc/core/Types.scala
diff options
context:
space:
mode:
authorMartin Odersky <odersky@gmail.com>2016-11-11 17:01:30 +0100
committerMartin Odersky <odersky@gmail.com>2016-11-11 17:01:30 +0100
commit49cef124a7be97647db3ccdbb0b775f53e5265d0 (patch)
tree4c8bd34a5f8050890adb409821c0c4023195500f /src/dotty/tools/dotc/core/Types.scala
parent49022717bc0e8c0de8834f4cde5021e1da8c0ea0 (diff)
downloaddotty-49cef124a7be97647db3ccdbb0b775f53e5265d0.tar.gz
dotty-49cef124a7be97647db3ccdbb0b775f53e5265d0.tar.bz2
dotty-49cef124a7be97647db3ccdbb0b775f53e5265d0.zip
Replace PolyType.fromSymbols with LambdaAbstract
As a side effect, avoid creating synthetic parameters in lambda abstract.
Diffstat (limited to 'src/dotty/tools/dotc/core/Types.scala')
-rw-r--r--src/dotty/tools/dotc/core/Types.scala8
1 files changed, 1 insertions, 7 deletions
diff --git a/src/dotty/tools/dotc/core/Types.scala b/src/dotty/tools/dotc/core/Types.scala
index ce308412b..a90fec2b4 100644
--- a/src/dotty/tools/dotc/core/Types.scala
+++ b/src/dotty/tools/dotc/core/Types.scala
@@ -2524,7 +2524,7 @@ object Types {
case _: MethodType => true
case _ => false
}
-
+
/** Is this polytype a higher-kinded type lambda as opposed to a polymorphic?
* method type? Only type lambdas get created with variances, that's how we can tell.
*/
@@ -2619,12 +2619,6 @@ object Types {
unique(new PolyType(paramNames, vs)(paramBoundsExp, resultTypeExp))
}
- def fromSymbols(tparams: List[Symbol], resultType: Type)(implicit ctx: Context): Type =
- if (tparams.isEmpty) resultType
- else apply(tparams map (_.name.asTypeName), tparams.map(_.variance))(
- pt => tparams.map(tparam => pt.lifted(tparams, tparam.info).bounds),
- pt => pt.lifted(tparams, resultType))
-
def unapply(tl: PolyType): Some[(List[LambdaParam], Type)] =
Some((tl.typeParams, tl.resType))