summaryrefslogtreecommitdiffstats
path: root/clang-tools-extra/clang-tidy/utils/IncludeSorter.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Update the file headers across all of the LLVM projects in the monorepoChandler Carruth2019-01-191-4/+3
| | | | | | | | | | | | | | | | | 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
* Correctly classify main file includes if there is a prefix addedAlexander Kornienko2017-01-121-1/+2
| | | | | | | | | | | | | | | | | Summary: Prevents misclassifying includes based on the command-line filename (e.g. if a project is in a subdirectory). This is slightly more robust than the additional duplicate detection, however the current classification scheme is still kind of brittle for a lot of code. Reviewers: hokein, alexfh Subscribers: cfe-commits, #clang-tools-extra Patch by Julian Bangert! Differential Revision: https://reviews.llvm.org/D26015 llvm-svn: 291767
* [clang-tidy] Fix a functional change from r269656.Benjamin Kramer2016-05-181-3/+4
| | | | | | | | Instead of forming char ranges that patch made us form token ranges, which behave subtly different. Sadly I'm only seeing this as part of a larger test case that I haven't fully reduced yet. llvm-svn: 269896
* [clang-tidy] Cleanups utils filesEtienne Bergeron2016-05-161-13/+4
| | | | | | | | | | | | | | | | | | | Summary: Cleanup some code by using appropriate APIs. Some coding style cleanups. There is no behavior changes. - Function `IncludeSorter::CreateFixIt` can be replaced by `FixItHint::CreateReplacement`. - Function `cleanPath` is a wrapper for `llvm::sys::path::remove_dots`. Reviewers: alexfh Subscribers: cfe-commits Differential Revision: http://reviews.llvm.org/D20279 llvm-svn: 269656
* [clang-tidy] Cleanup namespace in utils folder.Etienne Bergeron2016-05-031-0/+2
| | | | | | | | | | | | | | Summary: This is a step forward cleaning up the namespaces in clang-tidy/utils. There is no behavior change. Reviewers: alexfh Subscribers: cfe-commits Differential Revision: http://reviews.llvm.org/D19819 llvm-svn: 268356
* [clang-tidy] Sort includes case-sensitively.Alexander Kornienko2015-12-101-4/+1
| | | | | | | | | The motivation is: 1. consistency with clang-format, vim :sort etc. 2. we don't want the tools to depend on the current locale to do the include sorting llvm-svn: 255243
* Improved the misc-move-constructor-init check to identify arguments that are ↵Aaron Ballman2015-10-061-0/+9
| | | | | | | | passed by value but copy assigned to class data members when the non-deleted move constructor is a better fit. Patch by Felix Berger! llvm-svn: 249429
* SourceRanges are small and trivially copyable, don't them by reference. NFCCraig Topper2015-10-041-2/+2
| | | | llvm-svn: 249258
* [clang-tidy] Move IncludeSorter.* and IncludeInserter.* to clang-tidy/utils/Alexander Kornienko2015-08-141-0/+289
This is better structurally and it also fixes a linker error in the configure build. llvm-svn: 245052
OpenPOWER on IntegriCloud