We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 54ee9db commit a4f4632Copy full SHA for a4f4632
rule/nested-structs.go
@@ -37,6 +37,11 @@ type lintNestedStructs struct {
37
38
func (l *lintNestedStructs) Visit(n ast.Node) ast.Visitor {
39
switch v := n.(type) {
40
+ case *ast.TypeSpec:
41
+ _, isInterface := v.Type.(*ast.InterfaceType)
42
+ if isInterface {
43
+ return nil // do not analyze interface declarations
44
+ }
45
case *ast.FuncDecl:
46
if v.Body != nil {
47
ast.Walk(l, v.Body)
testdata/nested-structs.go
@@ -40,3 +40,8 @@ type Bad struct {
type issue744 struct {
c chan struct{}
}
+
+// issue 781
+type mySetInterface interface {
+ GetSet() map[string]struct{}
+}
0 commit comments