From 2d8f0deae424e29cd2ddd28c18b681930b54869e Mon Sep 17 00:00:00 2001 From: "marius a. eriksen" Date: Wed, 8 Jan 2014 20:51:27 +0000 Subject: [PATCH] [split] Future.followedBy->Future.before RB_ID=263637 --- util-core/src/main/scala/com/twitter/util/Future.scala | 2 +- util-core/src/test/scala/com/twitter/util/FutureTest.scala | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/util-core/src/main/scala/com/twitter/util/Future.scala b/util-core/src/main/scala/com/twitter/util/Future.scala index 11dc0a9890..ed6b08988c 100644 --- a/util-core/src/main/scala/com/twitter/util/Future.scala +++ b/util-core/src/main/scala/com/twitter/util/Future.scala @@ -737,7 +737,7 @@ abstract class Future[+A] extends Awaitable[A] { * discards the result of `this`. Note that this applies only * `Unit`-valued Futures -- i.e. side-effects.. */ - def followedBy[B](f: => Future[B])(implicit ev: this.type <:< Future[Unit]): Future[B] = + def before[B](f: => Future[B])(implicit ev: this.type <:< Future[Unit]): Future[B] = transform({ case Return(_) => f case Throw(t) => Future.rawException(t) diff --git a/util-core/src/test/scala/com/twitter/util/FutureTest.scala b/util-core/src/test/scala/com/twitter/util/FutureTest.scala index e6d46ba1d3..68fe92e297 100644 --- a/util-core/src/test/scala/com/twitter/util/FutureTest.scala +++ b/util-core/src/test/scala/com/twitter/util/FutureTest.scala @@ -820,7 +820,7 @@ class FutureTest extends WordSpec { } testSequence("flatMap", (a, next) => a flatMap { _ => next() }) - testSequence("followedBy", (a, next) => a followedBy next()) + testSequence("before", (a, next) => a before next()) "flatMap (values)" should { val f = Future(1) flatMap { x => Future(x + 1) }