Method GetArrayDataReference
- Namespace
- Zyl.VectorTraits.Impl.Util
- Assembly
- VectorTraits.dll
GetArrayDataReference<T>(T[])
Returns a reference to the 0th element of array. If the array is empty, returns a reference to where the 0th element would have been stored. Such a reference may be used for pinning but must never be dereferenced.
public static ref T GetArrayDataReference<T>(T[] array)
Parameters
array
T[]The array to analyze.
Returns
- T
Reference to the 0th element in array.
Type Parameters
T
The type of the array elements.
Exceptions
- NullReferenceException
array is null.
- See Also
-
GetArrayDataReference<T>(T[])