threads / patch / 3041

patch, 2 partsArgument order shouldn't matter

Subject: [PATCH 0/2] Argument order shouldn't matter

## tl;dr

One message between Jan 11, 2006 and Jan 11, 2006. Diffs are folded; open one to read it.

replies: 0people: 1as markdown or json

Andreas Ericsson· Jan 11, 2006, 20:42 UTC · lore

Many of the C-programs in the git suite are sensitive to argument ordering. That's a bit backwards for a modern tool-kit.

The first of these two patches provides some simple library code to handle arbitrary pointers in a stack-like manner, although in addition to stack_push() and stack_pop(), with their obvious meanings, there's also stack_pull() which fetches from the bottom of the stack. Err... that is, it fetches the least recently pushed item first.

The second patch is just an example of its implementation so we can get the discussions going.

--
 Makefile   |    4 ++--
 describe.c |   15 ++++++++++-----
 stack.c    |   42 ++++++++++++++++++++++++++++++++++++++++++
 stack.h    |    9 +++++++++
 4 files changed, 63 insertions(+), 7 deletions(-)
--
git version 1.1.0

← back to recent threads