com.qifun.statelessFuture.util
A wrapper that prevents compiler errors when you invoke Awaitable.await in a for block.
for
For example:
for (element <- seq) { // Compiler error: `await` must be enclosed in a `Future` block doSomething(element).await }
To suppress the error, wrap the original seq in a AwaitableSeq.futureSeq:
seq
for (element <- AwaitableSeq.futureSeq(seq)) { // No compiler error now doSomething(element).await }
A wrapper that prevents compiler errors when you invoke Awaitable.await in a
for
block.For example:
To suppress the error, wrap the original
seq
in a AwaitableSeq.futureSeq: