(e ast.NavigableExpr, exemptFunctions []string)
| 368 | } |
| 369 | |
| 370 | func inExemptFunction(e ast.NavigableExpr, exemptFunctions []string) bool { |
| 371 | parent, found := e.Parent() |
| 372 | for found { |
| 373 | if parent.Kind() == ast.CallKind { |
| 374 | fnName := parent.AsCall().FunctionName() |
| 375 | for _, exempt := range exemptFunctions { |
| 376 | if exempt == fnName { |
| 377 | return true |
| 378 | } |
| 379 | } |
| 380 | } |
| 381 | parent, found = parent.Parent() |
| 382 | } |
| 383 | return false |
| 384 | } |
| 385 | |
| 386 | func isOptionalIndex(i int, optIndices []int32) bool { |
| 387 | for _, optInd := range optIndices { |
no test coverage detected