diff --git a/pkg/analyzer/analyzer.go b/pkg/analyzer/analyzer.go index 5507d95..703cc1c 100644 --- a/pkg/analyzer/analyzer.go +++ b/pkg/analyzer/analyzer.go @@ -125,7 +125,7 @@ const ( ) func (n *nilNil) isDangerNilType(t types.Type) (bool, zeroValue) { - switch v := t.(type) { + switch v := types.Unalias(t).(type) { case *types.Pointer: return n.checkedTypes.Contains(ptrType), zeroValueNil