package
Version:
v0.0.0-...-4804628
Opens a new window with list of versions in this module.
Published: Mar 10, 2025
License: MIT
Opens a new window with license information.
Imports: 0
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
Package xslices provides more generic functions in the spirit of the slices package.
func Last[S ~[]E, E any](s S) E
Last returns the last element in s.
Last panics if len(s) == 0.
func Pop[S ~[]E, E any](s S, n int) S
Pop sets the last n elements of the slice to zero values
and returns s[:len(s)-n].
Source Files
¶
Click to show internal directories.
Click to hide internal directories.