opt(&conf)
}
- conf.Check(pkgName, files, nil)
+ // Provide Config.Info with all maps so that info recording is tested.
+ info := Info{
+ Types: make(map[syntax.Expr]TypeAndValue),
+ Instances: make(map[*syntax.Name]Instance),
+ Defs: make(map[*syntax.Name]Object),
+ Uses: make(map[*syntax.Name]Object),
+ Implicits: make(map[syntax.Node]Object),
+ Selections: make(map[*syntax.SelectorExpr]*Selection),
+ Scopes: make(map[syntax.Node]*Scope),
+ }
+ conf.Check(pkgName, files, &info)
if listErrors {
return
opt(&conf)
}
- conf.Check(pkgName, fset, files, nil)
+ // Provide Config.Info with all maps so that info recording is tested.
+ info := Info{
+ Types: make(map[ast.Expr]TypeAndValue),
+ Instances: make(map[*ast.Ident]Instance),
+ Defs: make(map[*ast.Ident]Object),
+ Uses: make(map[*ast.Ident]Object),
+ Implicits: make(map[ast.Node]Object),
+ Selections: make(map[*ast.SelectorExpr]*Selection),
+ Scopes: make(map[ast.Node]*Scope),
+ }
+ conf.Check(pkgName, fset, files, &info)
if listErrors {
return