DoxigAlpha

getLastOrNull

Returns the last element from the list, or null if list is empty.

Function parameters

Parameters

#

Deprecated.

Functions

#
Managed
Deprecated.
AlignedManaged
Deprecated.
Aligned
A contiguous, growable list of arbitrarily aligned items in memory.

Source

Implementation

#
pub fn getLastOrNull(self: Self) ?T {
    if (self.items.len == 0) return null;
    return self.getLast();
}