Skip to content

Releases: chenfeining/go-npecheck

publish v1.0.4

30 Jul 06:49
Compare
Choose a tag to compare

publish v1.0.4

publish npecheck

23 Jul 02:13
Compare
Choose a tag to compare

Check for potential nil pointer reference exceptions to compensate for go linter's shortcomings in this area. This linter is supposed to be the most rigorous and complete NPE solution

  1. Focus on detecting potential null pointer reference issues
  2. Support detecting potential null pointer references for function input parameters and external function assignments. For example, inputPtr.v, assignedPtr.v, the inputPtr, assignedPtr can be null pointers
  3. If the ancestor node is an external assignment pointer, it supports detecting chained variable references and whether there are potential null pointer references. For example, p1.p2.v, the p1, p2 may be null pointers
  4. If the parent node is an external assignment pointer, it supports detecting the problem of null pointer reference of chained functions. For example, m.getFunc().v, the m.GetFunc() may be a null pointer
  5. In the case of array from external assignment, support detection of array elements, potential null pointer reference problem