Mojo module
pointer
Implements the Pointer type.
You can import these APIs from the memory package. For example:
from memory import Pointercomptime values
GPUAddressSpace
comptime GPUAddressSpace = AddressSpace
Deprecated: Use AddressSpace instead. This alias is provided for backward compatibility and will be removed in a future release.
ImmutPointer
comptime ImmutPointer[_mlir_origin: LITImmutOrigin, //, type: AnyType, origin: ImmutOrigin, *, address_space: AddressSpace = AddressSpace.GENERIC] = Pointer[type, origin, address_space]
An immutable pointer.
Parameters
- _mlir_origin (
LITImmutOrigin): - type (
AnyType): The pointee type. - origin (
ImmutOrigin): The origin of the pointer. - address_space (
AddressSpace): The address space of the pointer.
MutPointer
comptime MutPointer[_mlir_origin: LITMutOrigin, //, type: AnyType, origin: MutOrigin, *, address_space: AddressSpace = AddressSpace.GENERIC] = Pointer[type, origin, address_space]
A mutable pointer.
Parameters
- _mlir_origin (
LITMutOrigin): - type (
AnyType): The pointee type. - origin (
MutOrigin): The origin of the pointer. - address_space (
AddressSpace): The address space of the pointer.
Structs
-
AddressSpace: Address space of the pointer. -
Pointer: Defines a non-nullable safe pointer.
Was this page helpful?
Thank you! We'll create more content like this.
Thank you for helping us improve!