Single-Item Pointers with *T
Point at exactly one value.
A Pointer Points
A pointer holds the address of a value living somewhere else in memory, instead of holding the value itself. 📍
The *T Type
A single-item pointer has the type *T, where T is what it points at. So *i32 means a pointer to one i32 value.
var p: *i32 = undefined;All lessons in this course
- Single-Item Pointers with *T
- Dereferencing with ptr.*
- Many-Item Pointers [*]T
- Const Pointers and Alignment