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

Consider toml.Decode vs toml.Unmarshal #76

Open
ccoVeille opened this issue Nov 16, 2024 · 4 comments
Open

Consider toml.Decode vs toml.Unmarshal #76

ccoVeille opened this issue Nov 16, 2024 · 4 comments

Comments

@ccoVeille
Copy link

ccoVeille commented Nov 16, 2024

I thought about your project by reading this PR

https://pkg.go.dev/github.com/BurntSushi/toml#Unmarshal

https://pkg.go.dev/github.com/BurntSushi/toml#Decode

https://github.com/BurntSushi/toml/blob/v1.4.0/decode.go#L24-L37

Could you have interest for supporting it?

@butuzov
Copy link
Owner

butuzov commented Nov 17, 2024

Yeah, it looks its "our" case and @golangci is already have its supported. I will gladly except PR from you or @alexandear if you are going to create one. I will also try to find time once ... once i have chance to sit calmly for an hour.

Cheers!

@ccoVeille
Copy link
Author

and golangci is already have its supported

I might have missed something then.

What do you mean?

@alexandear
Copy link
Contributor

As I understand it, the linter mirror is designed to only support finding mirroring functions in the standard library, not in third-party libraries like github.com/BurntSushi/toml.

@butuzov
Copy link
Owner

butuzov commented Nov 18, 2024

Correct!

  1. std lib first. However this package supported by main engine (i am considering gonagci-lint main engine for running mirror), so it can be OK to have its support.
  2. Issue I see now - Unmarshal and Decode has different signatures, therefore its not really really suitable for mirror (as alt function will need to have almost same signature).

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

No branches or pull requests

3 participants