dotnet / dotnet-api-docs

.NET API reference documentation (.NET 5+, .NET Core, .NET Framework)
https://docs.microsoft.com/dotnet/api/
Other
687 stars 1.52k forks source link

Add "Thread Safety" section for all types #9793

Open ViIvanov opened 3 months ago

ViIvanov commented 3 months ago

Documentation for some types contains "Thread Safety" section.

For example, for the System.String type it says, that

This type is thread safe.

and for some other types (like List<> here) it is more descriptive.

But the documentation for many types does not contain this section at all, for example for HashSet<> here.

Does it mean, that the type should be treated as

Public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

when the "Thread Safety" section does not exist in the documentation?

Otherwise, is it possible to add this section to all types?

dotnet-issue-labeler[bot] commented 3 months ago

I couldn't figure out the best area label to add to this issue. If you have write-permissions please help me learn by adding exactly one area label.