Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ TryUpdate< TKey, TValue >()

static bool System.Collections.Immutable.ImmutableInterlocked.TryUpdate< TKey, TValue > ( ref ImmutableDictionary< TKey, TValue > location,
TKey key,
TValue newValue,
TValue comparisonValue )
inlinestatic
Type Constraints
TKey :notnull 

Definition at line 218 of file ImmutableInterlocked.cs.

218 : notnull
219 {
222 bool flag;
223 do
224 {
225 Requires.NotNull(immutableDictionary, "location");
227 {
228 return false;
229 }
234 }
235 while (!flag);
236 return true;
237 }
bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
static int CompareExchange(ref int location1, int value, int comparand)
static bool Read(ref bool location)
Definition Volatile.cs:67

References System.Threading.Interlocked.CompareExchange(), System.key, System.Threading.Volatile.Read(), System.Collections.Generic.Dictionary< TKey, TValue >.TryGetValue(), and System.value.