[all-commits] [llvm/llvm-project] ce6de9: [clang-tidy] Fix `cppcoreguidelines-init-variables...

Liu Ke via All-commits all-commits at lists.llvm.org
Tue Feb 7 03:35:16 PST 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: ce6de98b80ada8efbff93766b5303db5ab052efc
      https://github.com/llvm/llvm-project/commit/ce6de98b80ada8efbff93766b5303db5ab052efc
  Author: Sockke <liuke.gehry at bytedance.com>
  Date:   2023-02-07 (Tue, 07 Feb 2023)

  Changed paths:
    M clang-tools-extra/clang-tidy/cppcoreguidelines/InitVariablesCheck.cpp
    M clang-tools-extra/test/clang-tidy/checkers/cppcoreguidelines/init-variables.cpp

  Log Message:
  -----------
  [clang-tidy] Fix `cppcoreguidelines-init-variables` for invalid vardecl

https://godbolt.org/z/n4cK4fo3o
The checker missed a check for invalid vardecl and this could cause a false positive.

Reviewed By: carlosgalvezp

Differential Revision: https://reviews.llvm.org/D138655




More information about the All-commits mailing list