Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

clang-tidy: Fix open findings #542

timwoj opened this issue Aug 14, 2019 · 0 comments


Copy link

commented Aug 14, 2019

Support was recently added for a clang-tidy build target and with that target we have a first set of findings. This is a catch-all GHI for fixing the existing issues before we start working on automated runs of clang-tidy as part of a CI build step.

The current findings:

   3 bugprone-exception-escape
   1 bugprone-incorrect-roundings
   2 bugprone-integer-division
  18 bugprone-macro-parentheses
 234 bugprone-narrowing-conversions
   4 bugprone-parent-virtual-call
   1 bugprone-sizeof-container
   1 bugprone-string-integer-assignment
  11 bugprone-suspicious-semicolon
   7 bugprone-suspicious-string-compare
  72 bugprone-too-small-loop-variable
   5 bugprone-unused-raii
   1 bugprone-unused-return-value
  38 clang-analyzer-core.CallAndMessage
   4 clang-analyzer-core.DivideZero
   3 clang-analyzer-core.NonNullParamChecker
  21 clang-analyzer-core.NullDereference
   1 clang-analyzer-core.UndefinedBinaryOperatorResult
   1 clang-analyzer-core.uninitialized.Assign
   1 clang-analyzer-core.uninitialized.Branch
   1 clang-analyzer-core.uninitialized.UndefReturn
  18 clang-analyzer-cplusplus.NewDelete
  83 clang-analyzer-cplusplus.NewDeleteLeaks
  33 clang-analyzer-deadcode.DeadStores
 122 clang-analyzer-optin.cplusplus.VirtualCall
   4 clang-analyzer-security.insecureAPI.bzero
   7 clang-analyzer-security.insecureAPI.rand
   4 clang-analyzer-security.insecureAPI.strcpy
   1 clang-analyzer-unix.MallocSizeof
   3 clang-analyzer-unix.cstring.NullArg
   9 performance-faster-string-find
   2 performance-for-range-copy
   5 performance-inefficient-string-concatenation
  17 performance-move-const-arg
   2 performance-noexcept-move-constructor
   3 performance-unnecessary-copy-initialization
  98 performance-unnecessary-value-param

To get a full set of results with traces and line numbers, run make clang-tidy in your build directory. The run will take about 20 minutes.

@jsiwek jsiwek added this to Unassigned / Todo in Release 3.1.0 via automation Sep 19, 2019

@jsiwek jsiwek added this to the 3.1.0 milestone Sep 19, 2019

@jsiwek jsiwek moved this from Unassigned / Todo to Assigned / In Progress in Release 3.1.0 Sep 19, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.