aboutsummaryrefslogtreecommitdiff
path: root/entry.c
diff options
context:
space:
mode:
authorMichael Haggerty <mhagger@alum.mit.edu>2017-04-16 08:41:34 +0200
committerJunio C Hamano <gitster@pobox.com>2017-04-16 21:32:46 -0700
commitdf30875987329bb46e54ec7be0eb29c33702de3a (patch)
tree6c2f92e2dbadf9554198da881f9ac002210d4565 /entry.c
parente00d1a4ff7d79b403bf97a0746138d584c9ebf9a (diff)
downloadgit-df30875987329bb46e54ec7be0eb29c33702de3a.tar.gz
git-df30875987329bb46e54ec7be0eb29c33702de3a.tar.xz
ref-cache: use a callback function to fill the cache
It is a leveling violation for `ref_cache` to know about `files_ref_store` or that it should call `read_loose_refs()` to lazily fill cache directories. So instead, have its constructor take as an argument a callback function that it should use for lazy-filling, and change `files_ref_store` to supply a pointer to function `read_loose_refs` (renamed to `loose_fill_ref_dir`) when creating the ref cache for its loose refs. This means that we can generify the type of the back-pointer in `struct ref_cache` from `files_ref_store` to `ref_store`. Signed-off-by: Michael Haggerty <mhagger@alum.mit.edu> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'entry.c')
0 files changed, 0 insertions, 0 deletions