Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

chore: enable use-any from revive #1784

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

mmorel-35
Copy link
Contributor

Description

use-any: Since Go 1.18, interface{} has an alias: any. This rule proposes to replace instances of interface{} with any.

@mmorel-35 mmorel-35 marked this pull request as ready for review January 30, 2025 06:56
@shirou
Copy link
Owner

shirou commented Jan 30, 2025

I don't know much about the Revive, but is it possibly only supported on Linux?. It seems net/net_windows.go and internal/common/common_windows.go have also interface{}.

@mmorel-35
Copy link
Contributor Author

I believe, that's probably more golangci-lint related you need to run it with differenr GOOS or GOARCH to cover them all.

@ccoVeille
Copy link

ccoVeille commented Jan 30, 2025

I took a look earlier because I was curious and I was about to post when I saw your reply @mmorel-35

You can find an explanation here

It's not really about GOARCH and co with golangci-lint, as the tool is already compiled.

So adding a golangci-lint job per arch via matrix seems the solution.

It's strange I had never faced this. So good catch @shirou TIL something and I'm happy about it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants