diff options
Diffstat (limited to 'test/files/run/Course-2002-05.scala')
-rw-r--r-- | test/files/run/Course-2002-05.scala | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/test/files/run/Course-2002-05.scala b/test/files/run/Course-2002-05.scala index 9f3304f690..bc5e98592d 100644 --- a/test/files/run/Course-2002-05.scala +++ b/test/files/run/Course-2002-05.scala @@ -51,7 +51,7 @@ module M0 { module M1 { def partition[a](xs: List[a], pred: a => boolean): Pair[List[a], List[a]] = { - xs.foldr[Pair[List[a], List[a]]](Pair(List(), List())) { + xs.foldRight[Pair[List[a], List[a]]](Pair(List(), List())) { (x, p) => if (pred (x)) Pair(x :: p._1, p._2) else Pair(p._1, x :: p._2) } } |