[all-commits] [llvm/llvm-project] bbc9f6: [clang-tidy] Add cert-oop58-cpp check

gaborbencze via All-commits all-commits at lists.llvm.org
Sun Dec 15 07:30:29 PST 2019


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: bbc9f6c2ef074668374e06a5de471413afd2ee4b
      https://github.com/llvm/llvm-project/commit/bbc9f6c2ef074668374e06a5de471413afd2ee4b
  Author: Gabor Bencze <b.gabor98 at gmail.com>
  Date:   2019-12-15 (Sun, 15 Dec 2019)

  Changed paths:
    M clang-tools-extra/clang-tidy/cert/CERTTidyModule.cpp
    M clang-tools-extra/clang-tidy/cert/CMakeLists.txt
    A clang-tools-extra/clang-tidy/cert/MutatingCopyCheck.cpp
    A clang-tools-extra/clang-tidy/cert/MutatingCopyCheck.h
    M clang-tools-extra/docs/ReleaseNotes.rst
    A clang-tools-extra/docs/clang-tidy/checks/cert-oop58-cpp.rst
    M clang-tools-extra/docs/clang-tidy/checks/list.rst
    A clang-tools-extra/test/clang-tidy/checkers/cert-oop58-cpp.cpp

  Log Message:
  -----------
  [clang-tidy] Add cert-oop58-cpp check
The check warns when (a member of) the copied object is assigned to in a
copy constructor or copy assignment operator. Based on
https://wiki.sei.cmu.edu/confluence/display/cplusplus/OOP58-CPP.+Copy+operations+must+not+mutate+the+source+object

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




More information about the All-commits mailing list