Skip to content

Commit 97d6fb5

Browse files
Martin Ågrengitster
authored andcommitted
cache.h: drop duplicate ensure_full_index() declaration
There are two identical declarations of `ensure_full_index()` in cache.h. Commit 3964fc2 ("sparse-index: add guard to ensure full index", 2021-03-30) provided an empty implementation of `ensure_full_index()`, declaring it in a new file sparse-index.h. When commit 4300f84 ("sparse-index: implement ensure_full_index()", 2021-03-30) fleshed out the implementation, it added an identical declaration to cache.h. Then 118a2e8 ("cache: move ensure_full_index() to cache.h", 2021-04-01) favored having the declaration in cache.h. Because of the double declaration, at that point we could have just dropped the one in sparse-index.h, but instead it got moved to cache.h. As a result, cache.h contains the exact same function declaration twice. Drop the one under "/* Name hashing */", in favor of the one under "/* Initialize and use the cache information */". Signed-off-by: Martin Ågren <[email protected]> Acked-by: Victoria Dye <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent e9d7761 commit 97d6fb5

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

cache.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -350,8 +350,6 @@ void add_name_hash(struct index_state *istate, struct cache_entry *ce);
350350
void remove_name_hash(struct index_state *istate, struct cache_entry *ce);
351351
void free_name_hash(struct index_state *istate);
352352

353-
void ensure_full_index(struct index_state *istate);
354-
355353
/* Cache entry creation and cleanup */
356354

357355
/*

0 commit comments

Comments
 (0)