[PATCH] D56160: created clang-tidy pass modernize-use-trailing-return
Bernhard Manfred Gruber via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Sun Dec 30 09:45:52 PST 2018
bernhardmgruber created this revision.
bernhardmgruber added a reviewer: alexfh.
bernhardmgruber added a project: clang-tools-extra.
Herald added subscribers: cfe-commits, mgorny.
The new clang-tidy pass modernize-use-trailing-return rewrites function signatures to use a trailing return type.
A fair amount of tests are included.
Does not work on return types which span locations before and after the function name (e.g. functions returning function pointers). The pass may fail if the return types are from missing headers (e.g. when clang-tidy is run without a compilation database or all needed include directories)
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D56160
Files:
clang-tidy/modernize/CMakeLists.txt
clang-tidy/modernize/ModernizeTidyModule.cpp
clang-tidy/modernize/UseTrailingReturnCheck.cpp
clang-tidy/modernize/UseTrailingReturnCheck.h
docs/clang-tidy/checks/modernize-use-trailing-return.rst
test/clang-tidy/modernize-use-trailing-return.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D56160.179733.patch
Type: text/x-patch
Size: 18473 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20181230/39259ceb/attachment.bin>
More information about the cfe-commits
mailing list