Re: [PATCH 04/16] treewide: remove unnecessary cache.h includes in source files
- From
Derrick Stolee <derrickstolee@github.com>
- Date
- Feb 23, 2023, 13:57 UTC
- Message-ID
- <577c07be-b62e-f2b7-9d59-ae4229ee1208@github.com>
- In-Reply-To
- <bec6f89d82c98c594f88a1fd5e3cd44973c9a1c2.1677139521.git.gitgitgadget@gmail.com>
On 2/23/2023 3:05 AM, Elijah Newren via GitGitGadget wrote:
Show 9 quoted lines
> From: Elijah Newren <newren@gmail.com>
>
> We had several C files include cache.h unnecessarily. Replace those
> with an include of "git-compat-util.h" instead. Much like the previous
> commit, these have all been verified via both ensuring that
> gcc -E $SOURCE_FILE | grep '"cache.h"'
> found no hits and that
> make DEVELOPER=1 ${OBJECT_FILE_FOR_SOURCE_FILE}
> successfully compiles without warnings.Show 10 quoted lines
> diff --git a/t/helper/test-run-command.c b/t/helper/test-run-command.c > index 3ecb830f4a8..67b42ef50eb 100644 > --- a/t/helper/test-run-command.c > +++ b/t/helper/test-run-command.c > @@ -9,8 +9,6 @@ > */ > > #include "test-tool.h" > -#include "git-compat-util.h" > -#include "cache.h"
This double-deletion initially caught me off guard, but then I double-checked your first patch where "test-tool.h" was an acceptable first include.
Thanks, -Stolee