From 95ee655fbe8a5d346aea00c42deeb7ca493cb757 Mon Sep 17 00:00:00 2001 From: Alexander Prendota Date: Wed, 17 Oct 2018 15:37:08 +0300 Subject: [PATCH] docs: fix examples indents (#2222) --- CONCURRENCY.md | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/CONCURRENCY.md b/CONCURRENCY.md index 660aba483dd..faa852ec773 100644 --- a/CONCURRENCY.md +++ b/CONCURRENCY.md @@ -27,20 +27,20 @@
```kotlin - val future = execute(TransferMode.SAFE, { SomeDataForWorker() }) { - // data returned by the second function argument comes to the - // worker routine as 'input' parameter. - input -> - // Here we create an instance to be returned when someone consumes result future. - WorkerResult(input.stringParam + " result") - } +val future = execute(TransferMode.SAFE, { SomeDataForWorker() }) { + // data returned by the second function argument comes to the + // worker routine as 'input' parameter. + input -> + // Here we create an instance to be returned when someone consumes result future. + WorkerResult(input.stringParam + " result") +} - future.consume { - // Here we see result returned from routine above. Note that future object or - // id could be transferred to another worker, so we don't have to consume future - // in same execution context it was obtained. - result -> println("result is $result") - } +future.consume { + // Here we see result returned from routine above. Note that future object or + // id could be transferred to another worker, so we don't have to consume future + // in same execution context it was obtained. + result -> println("result is $result") +} ```