[PATCH] D67578: New ClangTidy check to warn when writing to a dispatch_once_t variable.
Michael Wyman via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri Sep 13 15:29:46 PDT 2019
mwyman created this revision.
mwyman added reviewers: benhamilton, hokein, stephanemoore.
Herald added subscribers: cfe-commits, mgorny.
Herald added a project: clang.
Libdispatch documentation specifies that dispatch_once_ts must never have been non-zero, and assigning to them violates this.
Currently adding this to the `misc` module. Per discussion in https://reviews.llvm.org/D67567, perhaps this should be moved to a new, more specific module.
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D67578
Files:
clang-tools-extra/clang-tidy/misc/CMakeLists.txt
clang-tools-extra/clang-tidy/misc/DispatchOnceAssignmentCheck.cpp
clang-tools-extra/clang-tidy/misc/DispatchOnceAssignmentCheck.h
clang-tools-extra/clang-tidy/misc/MiscTidyModule.cpp
clang-tools-extra/docs/ReleaseNotes.rst
clang-tools-extra/docs/clang-tidy/checks/list.rst
clang-tools-extra/docs/clang-tidy/checks/misc-dispatch-once-assignment.rst
clang-tools-extra/test/clang-tidy/misc-dispatch-once-assignment.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D67578.220182.patch
Type: text/x-patch
Size: 7046 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20190913/628c7ff4/attachment-0001.bin>
More information about the cfe-commits
mailing list