From ce223fe7abc47af712382a64404604e75f9f4d20 Mon Sep 17 00:00:00 2001 From: Adriaan Moors Date: Thu, 16 Sep 2010 22:26:04 +0000 Subject: closes #1569, #3731: refactored dependent metho... closes #1569, #3731: refactored dependent method types to get rid of debruijn indices and use singleton types instead. this is the core of the dependent types refactoring, no implicit or inference changes (one baffling discovery: resultType should drop annotations that don't subclass TypeConstraint, even in the trivial case... wow -- thanks to Tiark for helping me figure it out on a terrace in Barcelona TODO: probably need a more principled approach to the propagation of plugin type-annotations) review by odersky --- test/files/run/constrained-types.check | 4 ++-- test/files/run/constrained-types.scala | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'test/files/run') diff --git a/test/files/run/constrained-types.check b/test/files/run/constrained-types.check index cc00a7c46b..8050017659 100644 --- a/test/files/run/constrained-types.check +++ b/test/files/run/constrained-types.check @@ -52,8 +52,8 @@ val y = b.y // should keep the annotation y: Int @Annot(Stuff.x) = 10 ----- -def m(x: String): String @Annot(x) = x // m should be annotated with a debruijn -m: (x$0:String)String @Annot(x) +def m(x: String): String @Annot(x) = x +m: (x: String)String @Annot(x) ----- val three = "three" diff --git a/test/files/run/constrained-types.scala b/test/files/run/constrained-types.scala index 59fd0b1b8c..c03c144ad1 100644 --- a/test/files/run/constrained-types.scala +++ b/test/files/run/constrained-types.scala @@ -45,7 +45,7 @@ object Test { "val y = b.y // should keep the annotation", - "def m(x: String): String @Annot(x) = x // m should be annotated with a debruijn", + "def m(x: String): String @Annot(x) = x", "val three = \"three\"", "val three2 = m(three:three.type) // should change x to three", "var four = \"four\"", -- cgit v1.2.3