Stephen Kelly
f2f920b987
[clang-tidy] Simplify inaccurate erase check
...
The normalization of matchers means that this now works in all language
modes.
Differential Revision: https://reviews.llvm.org/D96139
2021-02-13 13:51:27 +00:00
Alexander Kornienko
027899dab6
Remove references to the ast_type_traits namespace
...
Follow up to cd62511496
/
https://reviews.llvm.org/D74499
Reviewed By: aaron.ballman
Differential Revision: https://reviews.llvm.org/D92994
2020-12-11 00:58:46 +01:00
Stephen Kelly
a72307c3a6
Set traversal explicitly where needed in clang-tidy
...
Reviewers: aaron.ballman
Subscribers: nemanjai, kbarton, arphaman, cfe-commits
Tags: #clang
Differential Revision: https://reviews.llvm.org/D72530
2020-05-21 22:34:37 +01:00
Nathan James
e40a742a50
[clang-tidy] Change checks to use new isLanguageVersionSupported restriction
...
Summary: Modifies all checks that are language version dependent to use `isLanguageVersionSupported`
Reviewers: jdoerfert, lebedev.ri, aaron.ballman, gribozavr2, Eugene.Zelenko
Reviewed By: gribozavr2
Subscribers: wuzish, nemanjai, xazax.hun, hiraditya, kbarton, steven_wu, dexonsmith, arphaman, lebedev.ri, cfe-commits
Tags: #clang
Differential Revision: https://reviews.llvm.org/D75340
2020-03-03 16:43:45 +00:00
Benjamin Kramer
adcd026838
Make llvm::StringRef to std::string conversions explicit.
...
This is how it should've been and brings it more in line with
std::string_view. There should be no functional change here.
This is mostly mechanical from a custom clang-tidy check, with a lot of
manual fixups. It uncovers a lot of minor inefficiencies.
This doesn't actually modify StringRef yet, I'll do that in a follow-up.
2020-01-28 23:25:25 +01:00
Dmitri Gribenko
b641b914a3
Added an AST matcher for declarations that are in the `std` namespace
...
Reviewers: alexfh
Subscribers: cfe-commits
Tags: #clang
Differential Revision: https://reviews.llvm.org/D61480
llvm-svn: 359876
2019-05-03 12:50:00 +00:00
Chandler Carruth
2946cd7010
Update the file headers across all of the LLVM projects in the monorepo
...
to reflect the new license.
We understand that people may be surprised that we're moving the header
entirely to discuss the new license. We checked this carefully with the
Foundation's lawyer and we believe this is the correct approach.
Essentially, all code in the project is now made available by the LLVM
project under our new license, so you will see that the license headers
include that license only. Some of our contributors have contributed
code under our old license, and accordingly, we have retained a copy of
our old license notice in the top-level files in each project and
repository.
llvm-svn: 351636
2019-01-19 08:50:56 +00:00
Stephen Kelly
c09197e086
Port getLocEnd -> getEndLoc
...
Subscribers: nemanjai, ioeric, kbarton, cfe-commits
Differential Revision: https://reviews.llvm.org/D50355
llvm-svn: 339401
2018-08-09 22:43:02 +00:00
Stephen Kelly
43465bf3fd
Port getLocStart -> getBeginLoc
...
Reviewers: javed.absar
Subscribers: nemanjai, kbarton, ilya-biryukov, ioeric, jkorous, arphaman, jfb, cfe-commits
Differential Revision: https://reviews.llvm.org/D50354
llvm-svn: 339400
2018-08-09 22:42:26 +00:00
Alexander Kornienko
d4ac4afda7
[clang-tidy] Move a few more checks from misc to bugprone.
...
Summary:
clang_tidy/rename_check.py misc-assert-side-effect bugprone-assert-side-effect
clang_tidy/rename_check.py misc-bool-pointer-implicit-conversion bugprone-bool-pointer-implicit-conversion
clang_tidy/rename_check.py misc-fold-init-type bugprone-fold-init-type
clang_tidy/rename_check.py misc-forward-declaration-namespace bugprone-forward-declaration-namespace
clang_tidy/rename_check.py misc-inaccurate-erase bugprone-inaccurate-erase
clang_tidy/rename_check.py misc-move-forwarding-reference bugprone-move-forwarding-reference
clang_tidy/rename_check.py misc-multiple-statement-macro bugprone-multiple-statement-macro
clang_tidy/rename_check.py misc-use-after-move bugprone-use-after-move
clang_tidy/rename_check.py misc-virtual-near-miss bugprone-virtual-near-miss
Manually fixed a reference to UseAfterMoveCheck in the hicpp module.
Manually fixed header guards.
Reviewers: hokein
Reviewed By: hokein
Subscribers: nemanjai, mgorny, javed.absar, xazax.hun, kbarton, cfe-commits
Differential Revision: https://reviews.llvm.org/D40426
llvm-svn: 318950
2017-11-24 14:16:29 +00:00