summaryrefslogtreecommitdiff
path: root/t/t4013/diff.diff_initial..side
diff options
context:
space:
mode:
authorJeff King <peff@peff.net>2026-07-07 23:52:55 -0400
committerJunio C Hamano <gitster@pobox.com>2026-07-07 21:56:00 -0700
commit90a55e3a51525370798d9b484a74a51ad2b3f047 (patch)
tree0207233075ac7c394269fb2cc0da361979c3bc33 /t/t4013/diff.diff_initial..side
parentb87af5aa77c07f014e14c91ac5f942fdef132df9 (diff)
hash: document function pointers and wrappers
We want people to use the git_hash_*() wrappers rather than the bare function pointers in the git_hash_algo struct. Let's document them rather than the bare pointers, and warn people away from the pointers. Coccinelle will eventually force the use of the wrappers, but it's helpful to lead readers in the right direction from the start. While we're here we can document a few other bits of wisdom I've turned up while working in this area: - You have to initialize the destination of a git_hash_clone(). This is something we may eventually change for efficiency, but we should definitely document the requirement for now. - You must eventually finalize or discard a hash, since some backends may allocate resources during initialization. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t4013/diff.diff_initial..side')
0 files changed, 0 insertions, 0 deletions