From 37eabf615afe3de9733ea41cc9c522df3e2a6b87 Mon Sep 17 00:00:00 2001 From: Paul Phillips Date: Thu, 5 Apr 2012 10:31:22 -0700 Subject: Fix for continuations issue. Avoid explicit type arguments which don't conform to bounds where they could be successfully inferred. I had to disable one "neg" test which is no longer neg. Can anyone clue me in as to whether it is important? --- test/disabled/continuations-neg/infer0.check | 4 ++++ test/disabled/continuations-neg/infer0.scala | 12 ++++++++++++ 2 files changed, 16 insertions(+) create mode 100644 test/disabled/continuations-neg/infer0.check create mode 100644 test/disabled/continuations-neg/infer0.scala (limited to 'test/disabled') diff --git a/test/disabled/continuations-neg/infer0.check b/test/disabled/continuations-neg/infer0.check new file mode 100644 index 0000000000..1dd072ef09 --- /dev/null +++ b/test/disabled/continuations-neg/infer0.check @@ -0,0 +1,4 @@ +infer0.scala:11: error: cannot cps-transform expression 8: type arguments [Int(8),String,Int] do not conform to method shiftUnit's type parameter bounds [A,B,C >: B] + test(8) + ^ +one error found diff --git a/test/disabled/continuations-neg/infer0.scala b/test/disabled/continuations-neg/infer0.scala new file mode 100644 index 0000000000..6d97d7504d --- /dev/null +++ b/test/disabled/continuations-neg/infer0.scala @@ -0,0 +1,12 @@ +// $Id$ + +import scala.util.continuations._ + + +object Test { + def test(x: => Int @cpsParam[String,Int]) = 7 + + def main(args: Array[String]) { + test(8) + } +} -- cgit v1.2.3