mirror of
https://github.com/securego/gosec.git
synced 2025-11-23 22:15:04 +02:00
MatcMatchCompLit should be MatchCompList
This commit is contained in:
@@ -46,7 +46,7 @@ func MatchCall(n ast.Node, r *regexp.Regexp) *ast.CallExpr {
|
||||
return nil
|
||||
}
|
||||
|
||||
// MatcMatchCompLit will match an ast.CompositeLit if its string value obays the given regex.
|
||||
// MatchCompLit will match an ast.CompositeLit if its string value obays the given regex.
|
||||
func MatchCompLit(n ast.Node, r *regexp.Regexp) *ast.CompositeLit {
|
||||
t := reflect.TypeOf(&ast.CompositeLit{})
|
||||
if name, ok := selectName(n, t); ok && r.MatchString(name) {
|
||||
|
||||
Reference in New Issue
Block a user