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

Variable 'tests' conflicts with imported package name #29588

Closed
wants to merge 1 commit into from

Conversation

vcvvvc
Copy link

@vcvvvc vcvvvc commented Apr 19, 2024

One small question.
It conflicts with imported package name

import {
 //...
 "github.com/ethereum/go-ethereum/tests"
}

var tests map[string]tests.BlockTest

@holiman
Copy link
Contributor

holiman commented Apr 23, 2024

It doesn't appear to be a problem, since it compiles and none of our linters complain...?

@vcvvvc
Copy link
Author

vcvvvc commented Apr 23, 2024

It doesn't appear to be a problem, since it compiles and none of our linters complain...?

Yes, it's just a small problem with irregular naming 😂

@vcvvvc
Copy link
Author

vcvvvc commented Apr 23, 2024

It doesn't appear to be a problem, since it compiles and none of our linters complain...?

Due to the introduction of ‘github.com/ethereum/go-ethereum/tests’, a ‘tests’ is defined here as ‘var tests map[string]tests.BlockTest’. This could lead to unexpected behavior.
There is no problem here yet, just a parameter that can be optimized to avoid potential problems.

@fjl fjl closed this May 2, 2024
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.

None yet

3 participants