Skip to content

Commit

Permalink
Merge branch 'master' into develop
Browse files Browse the repository at this point in the history
  • Loading branch information
qwwdfsad committed May 25, 2021
2 parents 73942ee + c2d218a commit d8eb80e
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 6 deletions.
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ export JDK_18="$JAVA_HOME"

### Running the Knit tool

* Use [Knit](https://github.com/Kotlin/kotlinx-knit/blob/master/README.md) for updates to documentation:
* Use [Knit](https://github.com/Kotlin/kotlinx-knit/blob/main/README.md) for updates to documentation:
* Run `./gradlew knit` to update example files, links, tables of content.
* Commit updated documents and examples together with other changes.

Expand Down
8 changes: 5 additions & 3 deletions docs/topics/coroutines-basics.md
Original file line number Diff line number Diff line change
Expand Up @@ -152,10 +152,12 @@ suspend fun doWorld() = coroutineScope { // this: CoroutineScope

This code also prints:

<!--- TEST
```text
Hello
World!
-->
```

<!--- TEST -->

## Scope builder and concurrency

Expand All @@ -166,7 +168,7 @@ Let's launch two concurrent coroutines inside a `doWorld` suspending function:
import kotlinx.coroutines.*

//sampleStart
// Sequentially executes doWorld followed by "Hello"
// Sequentially executes doWorld followed by "Done"
fun main() = runBlocking {
doWorld()
println("Done")
Expand Down
2 changes: 1 addition & 1 deletion kotlinx-coroutines-core/common/src/flow/operators/Share.kt
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ import kotlin.jvm.*
* ### Upstream completion and error handling
*
* **Normal completion of the upstream flow has no effect on subscribers**, and the sharing coroutine continues to run. If a
* a strategy like [SharingStarted.WhileSubscribed] is used, then the upstream can get restarted again. If a special
* strategy like [SharingStarted.WhileSubscribed] is used, then the upstream can get restarted again. If a special
* action on upstream completion is needed, then an [onCompletion] operator can be used before the
* `shareIn` operator to emit a special value in this case, like this:
*
Expand Down
2 changes: 1 addition & 1 deletion kotlinx-coroutines-core/jvm/test/guide/example-basic-04.kt
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ package kotlinx.coroutines.guide.exampleBasic04

import kotlinx.coroutines.*

// Sequentially executes doWorld followed by "Hello"
// Sequentially executes doWorld followed by "Done"
fun main() = runBlocking {
doWorld()
println("Done")
Expand Down

0 comments on commit d8eb80e

Please sign in to comment.