[all-commits] [llvm/llvm-project] 36fcbb: Added readability-qualified-auto check

Nathan James via All-commits all-commits at lists.llvm.org
Tue Jan 14 11:06:54 PST 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 36fcbb838c8f293f46bfed78c6ed8c177f1e3485
      https://github.com/llvm/llvm-project/commit/36fcbb838c8f293f46bfed78c6ed8c177f1e3485
  Author: Nathan James <n.james93 at hotmail.co.uk>
  Date:   2020-01-14 (Tue, 14 Jan 2020)

  Changed paths:
    M clang-tools-extra/clang-tidy/llvm/LLVMTidyModule.cpp
    M clang-tools-extra/clang-tidy/readability/CMakeLists.txt
    A clang-tools-extra/clang-tidy/readability/QualifiedAutoCheck.cpp
    A clang-tools-extra/clang-tidy/readability/QualifiedAutoCheck.h
    M clang-tools-extra/clang-tidy/readability/ReadabilityTidyModule.cpp
    M clang-tools-extra/docs/ReleaseNotes.rst
    M clang-tools-extra/docs/clang-tidy/checks/list.rst
    A clang-tools-extra/docs/clang-tidy/checks/llvm-qualified-auto.rst
    A clang-tools-extra/docs/clang-tidy/checks/readability-qualified-auto.rst
    A clang-tools-extra/test/clang-tidy/checkers/readability-qualified-auto-cxx20.cpp
    A clang-tools-extra/test/clang-tidy/checkers/readability-qualified-auto.cpp

  Log Message:
  -----------
  Added readability-qualified-auto check

Adds a check that detects any auto variables that are deduced to a pointer or
a const pointer then adds in the const and asterisk according. Will also
check auto L value references that could be written as const. This relates
to the coding standard
https://llvm.org/docs/CodingStandards.html#beware-unnecessary-copies-with-auto




More information about the All-commits mailing list