Skip to content

No need for a for loop #2673

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

Merged
merged 1 commit into from Mar 4, 2020
Merged

No need for a for loop #2673

merged 1 commit into from Mar 4, 2020

Conversation

ghost
Copy link

@ghost ghost commented Feb 16, 2020

One of the infinite loops has an immediate check to see if next == CF_DISPATCH_ONCE_DONE. If it is, the loop will break. However, this infinite loop is simple enough to be changed into a while loop. It looks better too and results in more readable code.

@compnerd
Copy link
Member

@swift-ci please test Linux platform

@ghost
Copy link
Author

ghost commented Feb 25, 2020

Update?

@spevans spevans merged commit 58a6d3c into swiftlang:master Mar 4, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants