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
NonNullPointer
struct NonNullPointer[dtype_: DType, address_space_: AddressSpace = AddressSpace.GENERIC]
Fieldsβ
- βptr (
NonNullPointer[dtype_, address_space_].PtrType):
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 = False
PtrTypeβ
comptime PtrType = UnsafePointer[Scalar[NonNullPointer[dtype_, address_space_].dtype], ImmutAnyOrigin, address_space=NonNullPointer[dtype_, address_space_].address_space]
Methodsβ
__init__β
def __init__(ptr: UnsafePointer[Scalar[Self.dtype], ImmutAnyOrigin, address_space=Self.address_space]) -> Self
def __init__(ptr: DeviceBuffer[Self.dtype]) -> 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!