-
Notifications
You must be signed in to change notification settings - Fork 4.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Avoid runtime "atomic write" check in ConcurrentDictionary for shared…
… generics (#77005) ConcurrentDictionary caches an s_isValueWriteAtomic in a static readonly, but this trick does not work for shared generics. Extract the static readonly field to a class only dependent on TValue to handle more cases, and also add a reference type check up front to get a lot of the shared generics cases.
- Loading branch information
1 parent
3f600a1
commit e8fa4a7
Showing
1 changed file
with
51 additions
and
41 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters