HomeFreeBSD

queue(3): New *_SPLIT_AFTER(), *_ASSERT_EMPTY(), *_ASSERT_NONEMPTY()

Description

queue(3): New *_SPLIT_AFTER(), *_ASSERT_EMPTY(), *_ASSERT_NONEMPTY()

*_SPLIT_AFTER() allows to split an existing queue in two. It is the
missing block that enables arbitrary splitting and recombinations of
lists/queues together with *_CONCAT() and *_SWAP().

Add *_ASSERT_NONEMPTY(), used by *_SPLIT_AFTER().

Reviewed by: markj
MFC after: 3 days
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D49608 (stailq)
Differential Revision: https://reviews.freebsd.org/D49969 (rest)

Details

Provenance
olceAuthored on Feb 28 2025, 9:18 AM
Differential Revision
D49969: queue: New *_SPLIT_AFTER(), *_ASSERT_EMPTY(), *_ASSERT_NONEMPTY()
Parents
rGfd6b81712eb9: ps(1): Constify the format strings for canned displays
Branches
Unknown
Tags
Unknown