diff options
Diffstat (limited to 'docs/examples/futures.scala')
-rw-r--r-- | docs/examples/futures.scala | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/docs/examples/futures.scala b/docs/examples/futures.scala index 905d360612..79682b5b76 100644 --- a/docs/examples/futures.scala +++ b/docs/examples/futures.scala @@ -1,17 +1,17 @@ -package examples; +package examples -import concurrent.ops._; +import concurrent.ops._ object futures { - def someLengthyComputation = 1; - def anotherLengthyComputation = 2; - def f(x: Int) = x + x; - def g(x: Int) = x * x; + def someLengthyComputation = 1 + def anotherLengthyComputation = 2 + def f(x: Int) = x + x + def g(x: Int) = x * x def main(args: Array[String]): Unit = { - val x = future(someLengthyComputation); - anotherLengthyComputation; - val y = f(x()) + g(x()); + val x = future(someLengthyComputation) + anotherLengthyComputation + val y = f(x()) + g(x()) Console.println(y) } }
\ No newline at end of file |