]> Kevux Git Server - rit/commit
use commit_stack instead of prio_queue in LIFO mode
authorRené Scharfe <l.s.r@web.de>
Tue, 17 Mar 2026 21:40:07 +0000 (22:40 +0100)
committerJunio C Hamano <gitster@pobox.com>
Wed, 18 Mar 2026 17:39:56 +0000 (10:39 -0700)
commit1ae7a359ae53e98f153b8fb0dea532d2007a0093
tree3eae603e4bcd133211d43f56cf3552095842896b
parentca1db8a0f7dc0dbea892e99f5b37c5fe5861be71
use commit_stack instead of prio_queue in LIFO mode

A prio_queue with a NULL compare function acts as a stack -- the last
element in is the first one out (LIFO).  Use an actual commit_stack
instead where possible, as it documents the behavior better, provides
type safety and saves some memory because prio_queue stores an
additional tie-breaking counter per element.

Signed-off-by: René Scharfe <l.s.r@web.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/name-rev.c
negotiator/default.c
negotiator/skipping.c