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

Small fixes #152

Merged
merged 1 commit into from
Sep 3, 2019
Merged

Small fixes #152

merged 1 commit into from
Sep 3, 2019

Conversation

sungam3r
Copy link
Contributor

@sungam3r sungam3r commented Sep 3, 2019

Just documentation fixes and small changes.

#pragma warning disable 420 // ref to a volatile field
while (Interlocked.CompareExchange(ref _providers, added, existing) != existing)
#pragma warning restore 420
do
Copy link
Contributor Author

Choose a reason for hiding this comment

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

In this situation, the do-while loop is more appropriate instead of just while loop because it allows you to change variables in one place instead of two.

@nblumhardt
Copy link
Member

Great, thanks!

@nblumhardt nblumhardt merged commit c5bad0c into serilog:dev Sep 3, 2019
@sungam3r sungam3r deleted the small-refactor branch September 4, 2019 06:32
@nblumhardt nblumhardt mentioned this pull request Nov 1, 2021
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