dotnet / dotnet/dotnet-api-docs
ConditionalWeakTable does not release values if values reference the ConditionalWeaktable itself
Open
area-System.Runtime.CompilerServices
doc-enhancement
Pri3
- Dominant language
- C#
- Stars
- 949
- Forks
- 1.7k
- Avg merge
- 3d 27m
- Merged PRs (30d)
- 49
Description
This is a special case described at https://github.com/dotnet/corefx/issues/19765. The issue is if one of the values added to the `ConditionalWeakTable` references the table itself then one must call `Clear` (or use one of the other workarounds described on the issue) to ensure that there are no leaks.
This is not mentioned explicit on the docs but seems a special case that should be documented to save users from memory leaks.
Contributor guide
Assessment
This issue has not been assessed yet.