[all-commits] [llvm/llvm-project] 2740b2: Fix uninitialized value clang static analyzer warn...

Simon Pilgrim via All-commits all-commits at lists.llvm.org
Sat Jan 11 08:03:42 PST 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 2740b2d5d5f0f56c87024555bdcae4f91e595ddb
      https://github.com/llvm/llvm-project/commit/2740b2d5d5f0f56c87024555bdcae4f91e595ddb
  Author: Simon Pilgrim <llvm-dev at redking.me.uk>
  Date:   2020-01-11 (Sat, 11 Jan 2020)

  Changed paths:
    M llvm/lib/Transforms/Utils/CodeExtractor.cpp

  Log Message:
  -----------
  Fix uninitialized value clang static analyzer warning. NFC.


  Commit: ded237b58d56299f90ef44853ef79b039248b85e
      https://github.com/llvm/llvm-project/commit/ded237b58d56299f90ef44853ef79b039248b85e
  Author: Simon Pilgrim <llvm-dev at redking.me.uk>
  Date:   2020-01-11 (Sat, 11 Jan 2020)

  Changed paths:
    M clang/lib/Sema/SemaDecl.cpp

  Log Message:
  -----------
  Fix "pointer is null" static analyzer warning. NFCI.

Use castAs<> instead of getAs<> since the pointer is dereferenced immediately below and castAs will perform the null assertion for us.


  Commit: 16c53ffcb9d040f0396bf1ab42ca366f7e1f1e4d
      https://github.com/llvm/llvm-project/commit/16c53ffcb9d040f0396bf1ab42ca366f7e1f1e4d
  Author: Simon Pilgrim <llvm-dev at redking.me.uk>
  Date:   2020-01-11 (Sat, 11 Jan 2020)

  Changed paths:
    M clang/lib/CodeGen/CGExpr.cpp
    M clang/lib/CodeGen/CGExprCXX.cpp
    M clang/lib/CodeGen/CGExprScalar.cpp

  Log Message:
  -----------
  Fix "pointer is null" static analyzer warnings. NFCI.

Use castAs<> instead of getAs<> since the pointer is dereferenced immediately below and castAs will perform the null assertion for us.


  Commit: d87a76c9dae38b2a1ef63584aee82e74490dc83b
      https://github.com/llvm/llvm-project/commit/d87a76c9dae38b2a1ef63584aee82e74490dc83b
  Author: Simon Pilgrim <llvm-dev at redking.me.uk>
  Date:   2020-01-11 (Sat, 11 Jan 2020)

  Changed paths:
    M clang/lib/AST/MicrosoftMangle.cpp

  Log Message:
  -----------
  Fix "pointer is null" static analyzer warning. NFCI.

Use castAs<> instead of getAs<> since the pointer is dereferenced immediately within mangleCallingConvention and castAs will perform the null assertion for us.


  Commit: 93431f96a7b14ff03036bae77cc0197fdc98ad52
      https://github.com/llvm/llvm-project/commit/93431f96a7b14ff03036bae77cc0197fdc98ad52
  Author: Simon Pilgrim <llvm-dev at redking.me.uk>
  Date:   2020-01-11 (Sat, 11 Jan 2020)

  Changed paths:
    M clang/lib/CodeGen/CGStmtOpenMP.cpp

  Log Message:
  -----------
  Fix "pointer is null" static analyzer warning. NFCI.

Use cast<> instead of dyn_cast<> since we know that the pointer should be valid (and is dereferenced immediately).


  Commit: bf03944d5d9a7e7c8105c69dfa0d7e0d345644df
      https://github.com/llvm/llvm-project/commit/bf03944d5d9a7e7c8105c69dfa0d7e0d345644df
  Author: Simon Pilgrim <llvm-dev at redking.me.uk>
  Date:   2020-01-11 (Sat, 11 Jan 2020)

  Changed paths:
    M clang/lib/Sema/SemaCodeComplete.cpp

  Log Message:
  -----------
  Fix "pointer is null" static analyzer warnings. NFCI.

Use castAs<> instead of getAs<> since the pointers are dereferenced immediately and castAs will perform the null assertion for us.


Compare: https://github.com/llvm/llvm-project/compare/7c7ca5158373...bf03944d5d9a


More information about the All-commits mailing list