Skip to main content

Mojo module

unsafe_pointer_v2

Aliases

OpaqueImmutPointer

alias OpaqueImmutPointer[origin: ImmutableOrigin, *, address_space: AddressSpace = AddressSpace(0)] = UnsafePointerV2[NoneType, origin, address_space=address_space]

An immutable opaque pointer, equivalent to the C const void* type.

Parameters

OpaqueMutPointer

alias OpaqueMutPointer[origin: MutableOrigin, *, address_space: AddressSpace = AddressSpace(0)] = UnsafePointerV2[NoneType, origin, address_space=address_space]

A mutable opaque pointer, equivalent to the C void* type.

Parameters

OpaquePointerV2

alias OpaquePointerV2[mut: Bool, //, origin: Origin[mut], *, address_space: AddressSpace = AddressSpace(0)] = UnsafePointerV2[NoneType, origin, address_space=address_space]

An opaque pointer, equivalent to the C (const) void* type.

Parameters

UnsafeImmutPointer

alias UnsafeImmutPointer[type: AnyType, origin: ImmutableOrigin, *, address_space: AddressSpace = AddressSpace(0)] = UnsafePointerV2[type, origin, address_space=address_space]

An immutable unsafe pointer.

Parameters

UnsafeMutPointer

alias UnsafeMutPointer[type: AnyType, origin: MutableOrigin, *, address_space: AddressSpace = AddressSpace(0)] = UnsafePointerV2[type, origin, address_space=address_space]

A mutable unsafe pointer.

Parameters

Structs

  • UnsafePointerV2: UnsafePointerV2[T] represents an indirect reference to one or more values of type T consecutively in memory, and can refer to uninitialized memory.

Functions

  • alloc: Allocates contiguous storage for count elements of type with alignment alignment.

Was this page helpful?