@@ -130,7 +130,7 @@ object Future:
130130 * If the future is created in an Async context, it is added to the
131131 * children of that context's root.
132132 */
133- def apply [T ](body : Async ?=> T )(using ac : AsyncConfig ): Future [T ] =
133+ def apply [T ](body : Async ?=> T )(using ac : Async . Config ): Future [T ] =
134134 val f = RunnableFuture (body)(using ac.scheduler)
135135 ac.root.addChild(f)
136136 f
@@ -141,7 +141,7 @@ object Future:
141141 * If both futures succeed, succeed with their values in a pair. Otherwise,
142142 * fail with the failure that was returned first and cancel the other.
143143 */
144- def zip [T2 ](f2 : Future [T2 ])(using AsyncConfig ): Future [(T1 , T2 )] = Future :
144+ def zip [T2 ](f2 : Future [T2 ])(using Async . Config ): Future [(T1 , T2 )] = Future :
145145 Async .await(Async .either(f1, f2)) match
146146 case Left (Success (x1)) => (x1, f2.value)
147147 case Right (Success (x2)) => (f1.value, x2)
@@ -152,7 +152,7 @@ object Future:
152152 * If either task succeeds, succeed with the success that was returned first
153153 * and cancel the other. Otherwise, fail with the failure that was returned last.
154154 */
155- def alt [T2 >: T1 ](f2 : Future [T2 ])(using AsyncConfig ): Future [T2 ] = Future :
155+ def alt [T2 >: T1 ](f2 : Future [T2 ])(using Async . Config ): Future [T2 ] = Future :
156156 Async .await(Async .either(f1, f2)) match
157157 case Left (Success (x1)) => f2.cancel(); x1
158158 case Right (Success (x2)) => f1.cancel(); x2
@@ -187,7 +187,7 @@ end Future
187187class Task [+ T ](val body : Async ?=> T ):
188188
189189 /** Start a future computed from the `body` of this task */
190- def run (using AsyncConfig ) = Future (body)
190+ def run (using Async . Config ) = Future (body)
191191
192192end Task
193193
0 commit comments