Skip to content
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

[Doc] Explain why thread::yield_now could be used. #41982

Merged
merged 1 commit into from
May 16, 2017

Conversation

gamazeps
Copy link
Contributor

Part of #29378.

r? @steveklabnik

@gamazeps gamazeps changed the title Explain why thread::yield_now could be used. [Doc] Explain why thread::yield_now could be used. May 13, 2017
@gamazeps
Copy link
Contributor Author

gamazeps commented May 14, 2017

r? @rust-lang/docs

///
/// For example when polling on a resource, it is common to check that it is
/// available, and if not to yield in order to avoid busy waiting. Thus the
/// poll then yield, is a rather common pattern when implementing low-level
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This sentence is a bit confusing. "the poll then yield" for example is a bit hard to understand with just one reading. Don't hesitate to make the sentence longer if it helps the reader to understand more easily.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done :)

@GuillaumeGomez
Copy link
Member

Thanks!

@bors: r+ rollup

@bors
Copy link
Contributor

bors commented May 14, 2017

📌 Commit a9cb094 has been approved by GuillaumeGomez

@bors
Copy link
Contributor

bors commented May 14, 2017

⌛ Testing commit a9cb094 with merge c5ce0e6...

bors added a commit that referenced this pull request May 14, 2017
[Doc] Explain why `thread::yield_now` could be used.

Part of #29378.

r? @steveklabnik
@Mark-Simulacrum Mark-Simulacrum added the S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. label May 14, 2017
@bors
Copy link
Contributor

bors commented May 14, 2017

💔 Test failed - status-appveyor

@Mark-Simulacrum
Copy link
Member

Looks like tests just... hung? Stopped? I can't really tell. Either way, there's practically no way for that to be the fault of this PR.

@bors retry

@bors
Copy link
Contributor

bors commented May 14, 2017

⌛ Testing commit a9cb094 with merge 4c409dd...

@frewsxcv frewsxcv added the A-docs Area: documentation for any part of the project, including the compiler, standard library, and tools label May 14, 2017
@bors
Copy link
Contributor

bors commented May 14, 2017

💔 Test failed - status-appveyor

@Mark-Simulacrum
Copy link
Member

test malformed_override ... ok
test unused_keys ... ok
test both_git_and_path_specified has been running for over 60 seconds

@bors retry

Mark-Simulacrum added a commit to Mark-Simulacrum/rust that referenced this pull request May 14, 2017
…umeGomez

[Doc] Explain why `thread::yield_now` could be used.

Part of rust-lang#29378.

r? @steveklabnik
frewsxcv added a commit to frewsxcv/rust that referenced this pull request May 15, 2017
…umeGomez

[Doc] Explain why `thread::yield_now` could be used.

Part of rust-lang#29378.

r? @steveklabnik
frewsxcv added a commit to frewsxcv/rust that referenced this pull request May 15, 2017
…umeGomez

[Doc] Explain why `thread::yield_now` could be used.

Part of rust-lang#29378.

r? @steveklabnik
frewsxcv added a commit to frewsxcv/rust that referenced this pull request May 16, 2017
…umeGomez

[Doc] Explain why `thread::yield_now` could be used.

Part of rust-lang#29378.

r? @steveklabnik
Mark-Simulacrum added a commit to Mark-Simulacrum/rust that referenced this pull request May 16, 2017
…umeGomez

[Doc] Explain why `thread::yield_now` could be used.

Part of rust-lang#29378.

r? @steveklabnik
Mark-Simulacrum added a commit to Mark-Simulacrum/rust that referenced this pull request May 16, 2017
…umeGomez

[Doc] Explain why `thread::yield_now` could be used.

Part of rust-lang#29378.

r? @steveklabnik
bors added a commit that referenced this pull request May 16, 2017
Rollup of 8 pull requests

- Successful merges: #41489, #41982, #41994, #41995, #42001, #42005, #42011, #42028
- Failed merges:
@bors bors merged commit a9cb094 into rust-lang:master May 16, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-docs Area: documentation for any part of the project, including the compiler, standard library, and tools S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants