You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Initialize the value referenced by target in a thread-safe manner. The value is changed to initializedValue only if the current value is uninitializedValue.
Namespace:CodeJam.Threading Assembly: CodeJam (in CodeJam.dll) Version: 2.1.0.0
static memberInitialize:target :'T byref * initializedValue : 'T * uninitializedValue : 'T -> 'T when 'T : not struct
Parameters
target
Type: T Reference to the target location.
initializedValue
Type: T The value to use if the target is currently uninitialized.
uninitializedValue
Type: T The uninitialized value.
Type Parameters
T
Type of value.
Return Value
Type: T The new value referenced by target. Note that this is nearly always more useful than the usual return from CompareExchange(T)(T, T, T) because it saves another read to target.