-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Update docs for CompareExchange\<T> #11422
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
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR updates the XML documentation for the CompareExchange methods by revising type parameter descriptions and summary texts. Key changes include:
- Removing the explicit reference type constraint from the type parameter T.
- Updating summary tags to use consistently.
- Reformulating the remarks section to streamline the note about method overload preference.
Comments suppressed due to low confidence (2)
xml/System.Threading/Interlocked.xml:1344
- The removal of the explicit reference type constraint on T may be intentional; consider adding a brief note explaining this change to clarify the updated usage.
<typeparam name="T">The type to be used for <paramref name="location1" />, <paramref name="value" />, and <paramref name="comparand" />.</typeparam>
xml/System.Threading/Interlocked.xml:2380
- [nitpick] Consider retaining the [!NOTE] markup format for this note to maintain consistency with other documentation sections, if that aligns with the project's style guidelines.
This method overload is preferable to the <xref:System.Threading.Interlocked.Exchange%28System.Object%40%2CSystem.Object%29> method overload, because the latter requires late-bound access to the destination object.
This is a follow for .NET 9 change dotnet/runtime#104558 . |
Fixes #11419.