Formatting Future.scala

This commit is contained in:
Viktor Klang 2011-12-30 15:04:59 +01:00
parent f22f229619
commit 4c7d9cbc1e

View file

@ -458,7 +458,7 @@ sealed trait Future[+T] extends japi.Future[T] with Await.Awaitable[T] {
val future = Promise[A]()
onComplete {
case l: Left[_, _] future complete l.asInstanceOf[Either[Throwable, A]]
case Right(res) future complete (try { Right(f(res)) } catch { case e: Exception Left(e) } )
case Right(res) future complete (try { Right(f(res)) } catch { case e: Exception Left(e) })
}
future
}