Function next [src]
Returns the next DevicePath node in the sequence, if any.
Prototype
pub fn next(self: *const DevicePath) ?*const DevicePath
Parameters
self: *const DevicePath
Source
pub fn next(self: *const DevicePath) ?*const DevicePath {
const bytes: [*]const u8 = @ptrCast(self);
const next_node: *const DevicePath = @ptrCast(bytes + self.length);
if (next_node.type == .end and @as(uefi.DevicePath.End.Subtype, @enumFromInt(self.subtype)) == .end_entire)
return null;
return next_node;
}