diff options
author | Nguyễn Thái Ngọc Duy <pclouds@gmail.com> | 2019-01-24 08:29:12 (GMT) |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2019-01-24 19:55:06 (GMT) |
commit | f8adbec9feaa7a1ab9814db1115826e87033712e (patch) | |
tree | 5049172d68705c068c5cc0ea40a3f6afcf443fa5 /t/helper | |
parent | 150fe065f71778a6591566d6fde65171569a4b7a (diff) | |
download | git-f8adbec9feaa7a1ab9814db1115826e87033712e.zip git-f8adbec9feaa7a1ab9814db1115826e87033712e.tar.gz git-f8adbec9feaa7a1ab9814db1115826e87033712e.tar.bz2 |
cache.h: flip NO_THE_INDEX_COMPATIBILITY_MACROS switch
By default, index compat macros are off from now on, because they
could hide the_index dependency.
Only those in builtin can use it.
Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/helper')
-rw-r--r-- | t/helper/test-dump-fsmonitor.c | 4 | ||||
-rw-r--r-- | t/helper/test-dump-untracked-cache.c | 1 | ||||
-rw-r--r-- | t/helper/test-tool.h | 1 |
3 files changed, 4 insertions, 2 deletions
diff --git a/t/helper/test-dump-fsmonitor.c b/t/helper/test-dump-fsmonitor.c index 08e3684..2786f47 100644 --- a/t/helper/test-dump-fsmonitor.c +++ b/t/helper/test-dump-fsmonitor.c @@ -3,11 +3,11 @@ int cmd__dump_fsmonitor(int ac, const char **av) { - struct index_state *istate = &the_index; + struct index_state *istate = the_repository->index; int i; setup_git_directory(); - if (do_read_index(istate, get_index_file(), 0) < 0) + if (do_read_index(istate, the_repository->index_file, 0) < 0) die("unable to read index file"); if (!istate->fsmonitor_last_update) { printf("no fsmonitor\n"); diff --git a/t/helper/test-dump-untracked-cache.c b/t/helper/test-dump-untracked-cache.c index 52870eb..cf0f2c7 100644 --- a/t/helper/test-dump-untracked-cache.c +++ b/t/helper/test-dump-untracked-cache.c @@ -1,3 +1,4 @@ +#define USE_THE_INDEX_COMPATIBILITY_MACROS #include "test-tool.h" #include "cache.h" #include "dir.h" diff --git a/t/helper/test-tool.h b/t/helper/test-tool.h index 042f124..f4fb3b9 100644 --- a/t/helper/test-tool.h +++ b/t/helper/test-tool.h @@ -1,6 +1,7 @@ #ifndef TEST_TOOL_H #define TEST_TOOL_H +#define USE_THE_INDEX_COMPATIBILITY_MACROS #include "git-compat-util.h" int cmd__chmtime(int argc, const char **argv); |