Skip to content

Conversation

@Ethan0456
Copy link

@Ethan0456 Ethan0456 commented Mar 11, 2025

Summary

While exploring how Git searches for .gitignore files and manages ignored files, I came across dir.h. While reading through the file, I noticed that struct repository; was forward-declared twice. This duplication appears unnecessary, and removing the second declaration compiles cleanly.

The `struct repository;` forward declaration appears twice in `dir.h`:
once at line 10 and again at line 46. This duplication is unnecessary
and likely unintentional.

Removing the second declaration has no impact on compilation, as verified
by a clean build.

Signed-off-by: Abhijeetsingh Meena <[email protected]>
@Ethan0456
Copy link
Author

/preview

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 11, 2025

Preview email sent as [email protected]

@Ethan0456
Copy link
Author

/submit

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 11, 2025

Submitted as [email protected]

To fetch this version into FETCH_HEAD:

git fetch https://github.com/gitgitgadget/git/ pr-1879/Ethan0456/cleanup/deduplicate-repo-fwd-decl-v1

To fetch this version to local tag pr-1879/Ethan0456/cleanup/deduplicate-repo-fwd-decl-v1:

git fetch --no-tags https://github.com/gitgitgadget/git/ tag pr-1879/Ethan0456/cleanup/deduplicate-repo-fwd-decl-v1

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 11, 2025

On the Git mailing list, Junio C Hamano wrote (reply to this):

"Abhijeetsingh Meena via GitGitGadget" <[email protected]>
writes:

> From: Abhijeetsingh Meena <[email protected]>
>
> The `struct repository;` forward declaration appears twice in `dir.h`:
> once at line 10 and again at line 46. This duplication is unnecessary
> and likely unintentional.
>
> Removing the second declaration has no impact on compilation, as verified
> by a clean build.
>
> Signed-off-by: Abhijeetsingh Meena <[email protected]>
> ---

Thanks.  Will apply.

>  dir.h | 1 -
>  1 file changed, 1 deletion(-)
>
> diff --git a/dir.h b/dir.h
> index a3a2f00f5d9..e659c47ad77 100644
> --- a/dir.h
> +++ b/dir.h
> @@ -43,7 +43,6 @@ struct repository;
>   *
>   */
>  
> -struct repository;
>  
>  struct dir_entry {
>  	unsigned int len;
>
> base-commit: ef8ce8f3d4344fd3af049c17eeba5cd20d98b69f

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 11, 2025

This patch series was integrated into seen via git@94dfd81.

@gitgitgadget gitgitgadget bot added the seen label Mar 11, 2025
@gitgitgadget
Copy link

gitgitgadget bot commented Mar 12, 2025

This branch is now known as am/dir-dedup-decl-of-repository.

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 12, 2025

This patch series was integrated into seen via git@f6da788.

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 12, 2025

There was a status update in the "New Topics" section about the branch am/dir-dedup-decl-of-repository on the Git mailing list:

Code cleanup.

Will merge to 'next'.
source: <[email protected]>

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 13, 2025

This patch series was integrated into seen via git@48e4fa7.

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 14, 2025

This patch series was integrated into seen via git@dd46f94.

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 14, 2025

There was a status update in the "Cooking" section about the branch am/dir-dedup-decl-of-repository on the Git mailing list:

Code cleanup.

Will merge to 'next'.
source: <[email protected]>

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 14, 2025

This patch series was integrated into seen via git@fcc0a1e.

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 15, 2025

This patch series was integrated into seen via git@e06c63b.

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 15, 2025

This patch series was integrated into seen via git@898b000.

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 18, 2025

This patch series was integrated into seen via git@2278c08.

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 18, 2025

This patch series was integrated into seen via git@03e8ba1.

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 18, 2025

This patch series was integrated into next via git@9075454.

@gitgitgadget gitgitgadget bot added the next label Mar 18, 2025
@gitgitgadget
Copy link

gitgitgadget bot commented Mar 18, 2025

This patch series was integrated into seen via git@3e03cdb.

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 18, 2025

There was a status update in the "Cooking" section about the branch am/dir-dedup-decl-of-repository on the Git mailing list:

Code cleanup.

Will merge to 'master'.
source: <[email protected]>

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 21, 2025

This patch series was integrated into seen via git@1cd5a5b.

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 21, 2025

There was a status update in the "Cooking" section about the branch am/dir-dedup-decl-of-repository on the Git mailing list:

Code cleanup.

Will merge to 'master'.
source: <[email protected]>

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 24, 2025

This patch series was integrated into seen via git@055cbd4.

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 25, 2025

This patch series was integrated into seen via git@77f9b97.

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 26, 2025

There was a status update in the "Cooking" section about the branch am/dir-dedup-decl-of-repository on the Git mailing list:

Code cleanup.

Will merge to 'master'.
source: <[email protected]>

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 28, 2025

This patch series was integrated into seen via git@e91937e.

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 29, 2025

This patch series was integrated into seen via git@f3db666.

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 29, 2025

This patch series was integrated into master via git@f3db666.

@gitgitgadget
Copy link

gitgitgadget bot commented Mar 29, 2025

This patch series was integrated into next via git@f3db666.

@gitgitgadget gitgitgadget bot added the master label Mar 29, 2025
@gitgitgadget gitgitgadget bot closed this Mar 29, 2025
@gitgitgadget
Copy link

gitgitgadget bot commented Mar 29, 2025

Closed via f3db666.

webstech added a commit that referenced this pull request Nov 5, 2025
…lint-9.25.0

build(deps-dev): bump eslint from 9.24.0 to 9.25.0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant