[PATCH] D42730: Add clang-tidy check for use of types/classes/functions from functional.h which are deprecated and removed in C++17

Jens Massberg via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Jan 31 03:14:21 PST 2018


massberg created this revision.
massberg added a reviewer: alexfh.
Herald added subscribers: cfe-commits, hintonda, mgorny.

In C++17 several classes, types and functions from functional.h are no longer available.
In this change we add first clang-tidy checks for occurrences of

- std::unary_function
- std::binary_function
- std::ptr_fun
- std::mem_fun

As there are several more deprecated types in functional.h, this check will be extended in the future.


Repository:
  rCTE Clang Tools Extra

https://reviews.llvm.org/D42730

Files:
  clang-tidy/modernize/AvoidFunctionalCheck.cpp
  clang-tidy/modernize/AvoidFunctionalCheck.h
  clang-tidy/modernize/CMakeLists.txt
  clang-tidy/modernize/ModernizeTidyModule.cpp
  docs/ReleaseNotes.rst
  docs/clang-tidy/checks/list.rst
  docs/clang-tidy/checks/modernize-avoid-functional.rst
  test/clang-tidy/modernize-avoid-functional.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D42730.132131.patch
Type: text/x-patch
Size: 9263 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20180131/4a2ede3b/attachment.bin>


More information about the cfe-commits mailing list