System::Runtime::CompilerServices::Unsafe class

Unsafe class

Provides low-level operations for unsafe memory manipulation.

class Unsafe

Methods

MethodDescription
static AsPointer(T&)Returns a pointer to the specified value.
static SizeOf()Returns the size of the specified type.

Remarks

This class is intended for advanced scenarios where direct memory access is required. It provides methods to obtain pointers to managed objects and to determine the size of types at runtime.

See Also