For the complete documentation index, see llms.txt. Markdown versions of all pages are available by appending .md to any URL (e.g. /max/get-started.md).
Mojo struct
NullPointer
struct NullPointer[dtype_: DType, address_space_: AddressSpace = AddressSpace.GENERIC]
A pointer known at compile time to be null, used when an optional pointer argument is absent.
Parametersβ
- βdtype_ (
DType): Element type of the pointed-to values. - βaddress_space_ (
AddressSpace): GPU address space of the pointer (defaults toAddressSpace.GENERIC).
Implemented traitsβ
AnyType,
Copyable,
ImplicitlyCopyable,
ImplicitlyDeletable,
Movable,
OptionalPointer,
RegisterPassable,
TrivialRegisterPassable
comptime membersβ
address_spaceβ
comptime address_space = address_space_
dtypeβ
comptime dtype = dtype_
is_nullβ
comptime is_null = True
PtrTypeβ
comptime PtrType = Pointer[Scalar[NullPointer[dtype_, address_space_].dtype], ImmutAnyOrigin, address_space=NullPointer[dtype_, address_space_].address_space, _safe=False]
Methodsβ
__init__β
def __init__() -> Self
valueβ
def value(self) -> Self.PtrType
Returns:
Self.PtrType
Was this page helpful?
Thank you! We'll create more content like this.
Thank you for helping us improve!