Skip to content

govet: add appends analyzer #4127

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Merged
merged 2 commits into from
Oct 12, 2023
Merged

Conversation

Antonboom
Copy link
Contributor

@Antonboom Antonboom commented Oct 12, 2023

No description provided.

@Antonboom Antonboom added the enhancement New feature or improvement label Oct 12, 2023
@ldez ldez added the linter: update Update the linter implementation inside golangci-lint label Oct 12, 2023
@ldez ldez changed the title govet: add appends analyzer; update default analyzers; update config reference govet: add appends analyzer Oct 12, 2023
@ldez
Copy link
Member

ldez commented Oct 12, 2023

I understand why you added default values for enable and disable but it's not their default values: if you disable-all default passes are not the same as if you enable-all.

The default passes are unrelated to enable and disable.

@ldez ldez merged commit 6491317 into golangci:master Oct 12, 2023
@Antonboom
Copy link
Contributor Author

Antonboom commented Oct 13, 2023

@ldez

Any other idea how to highlight default values?

I was confused with empty list.
And for me it is more unobvious than different sets at disable and disable-all.

We can write

    # Disable all analyzers (not just those that are disabled by default).
    # Default: false
    disable-all: true

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
enhancement New feature or improvement linter: update Update the linter implementation inside golangci-lint
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants