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

◆ ReturnToCache()

void System.Runtime.CompilerServices.PoolingAsyncValueTaskMethodBuilder< TResult >.StateMachineBox< TStateMachine >.ReturnToCache ( )
inlineprivateinherited

Definition at line 171 of file PoolingAsyncValueTaskMethodBuilder.cs.

172 {
174 _valueTaskSource.Reset();
175 if (t_tlsCache == null)
176 {
177 t_tlsCache = this;
178 return;
179 }
180 ref StateMachineBox<TStateMachine> perCoreCacheSlot = ref PerCoreCacheSlot;
181 if (perCoreCacheSlot == null)
182 {
183 Volatile.Write(ref perCoreCacheSlot, this);
184 }
185 }
static void Write(ref bool location, bool value)
Definition Volatile.cs:74

References System.Runtime.CompilerServices.PoolingAsyncValueTaskMethodBuilder< TResult >.StateMachineBox< TStateMachine >._valueTaskSource, System.Runtime.CompilerServices.PoolingAsyncValueTaskMethodBuilder< TResult >.StateMachineBox< TStateMachine >.ClearStateUponCompletion(), System.Runtime.CompilerServices.PoolingAsyncValueTaskMethodBuilder< TResult >.StateMachineBox< TStateMachine >.PerCoreCacheSlot, System.Runtime.CompilerServices.PoolingAsyncValueTaskMethodBuilder< TResult >.StateMachineBox< TStateMachine >.t_tlsCache, and System.Threading.Volatile.Write().

Referenced by System.Runtime.CompilerServices.PoolingAsyncValueTaskMethodBuilder< TResult >.StateMachineBox< TStateMachine >.GetResult().