Skip to content

Coroutines "Select expression" docs page is inaccurate #3385

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
awoSYS opened this issue Aug 1, 2022 · 1 comment
Closed

Coroutines "Select expression" docs page is inaccurate #3385

awoSYS opened this issue Aug 1, 2022 · 1 comment
Labels
docs KDoc and API reference

Comments

@awoSYS
Copy link

awoSYS commented Aug 1, 2022

Hi! I'm no Kotlin expert, just noticed a confusing detail on the Select expression docs page:

There's a runnable example, which, when clicking on the play button, produces output:

fizz -> 'Fizz'
buzz -> 'Buzz!'
fizz -> 'Fizz'
fizz -> 'Fizz'
buzz -> 'Buzz!'
fizz -> 'Fizz'
fizz -> 'Fizz'

Which looks in line with the contents of the docs page so far. However, the page states:

"The result of this code is:

fizz -> 'Fizz'
buzz -> 'Buzz!'
fizz -> 'Fizz'
fizz -> 'Fizz'
buzz -> 'Buzz!'
fizz -> 'Fizz'
buzz -> 'Buzz!'

"

Note the last line.

Looks like a typo to me, since at the 7th execution, fizz() should take precedence, right?

@qwwdfsad qwwdfsad added the docs KDoc and API reference label Aug 2, 2022
@qwwdfsad
Copy link
Collaborator

qwwdfsad commented Aug 2, 2022

Thanks for spotting!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs KDoc and API reference
Projects
None yet
Development

No branches or pull requests

2 participants