Open
Description
Your feature request related to a problem? Please describe.
The untypedconst
linter ensures that untyped constant expressions are not used as values of defined type (a.k.a. named type).
// The first call is valid as it is passing a typed-constant to "takesExString" which expects a typed-constant as its first parameter.
// The second call is invalid as it passes an untyped-constant which has the same underlying type as the one expected (string)
func Call() {
takesExString(external.ExStr)
takesExString("hoge") // want `passing untyped constant to parameter of defined type "github.com/jiftechnify/untypedconst/pkg/external.ExString"`
[..]
https://github.com/jiftechnify/untypedconst
Describe the solution you'd like.
—
Describe alternatives you've considered.
—
Additional context.
No response