summaryrefslogtreecommitdiffstats
path: root/clang-tools-extra/clang-tidy/modernize/UseEmplaceCheck.h
Commit message (Collapse)AuthorAgeFilesLines
* [clang-tidy] Switch checks to #include "ClangTidyCheck.h"Alexander Kornienko2019-03-251-1/+1
| | | | llvm-svn: 356892
* 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
* [clang-tidy] Add modernize-use-emplace.IgnoreImplicitConstructors optionAlexander Kornienko2017-08-101-4/+5
| | | | llvm-svn: 310584
* [clang-tidy] modernize-use-emplace: Remove unnecessary make_tuple callsJakub Kuderski2017-05-161-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | Summary: This patch makes modernize-use-emplace remove unnecessary make_ calls from push_back calls and turn them into emplace_back -- the same way make_pair calls are handled. Custom make_ calls can be removed for custom tuple-like types -- two new options that control that are `TupleTypes` and `TupleMakeFunctions`. By default, the check removes calls to `std::make_pair` and `std::make_tuple`. Eq. ``` std::vector<std::tuple<int, char, bool>> v; v.push_back(std::make_tuple(1, 'A', true)); // --> v.emplace_back(1, 'A', true); ``` Reviewers: alexfh, aaron.ballman, Prazek, hokein Reviewed By: Prazek Subscribers: JDevlieghere, xazax.hun, JonasToth, cfe-commits Tags: #clang-tools-extra Differential Revision: https://reviews.llvm.org/D32690 llvm-svn: 303145
* Revert "[clang-tidy] modernize-use-emplace: Remove unnecessary make_tuple calls"Jakub Kuderski2017-05-161-2/+0
| | | | | | This reverts commit r303139. The commit made docs build emit a warning. llvm-svn: 303140
* [clang-tidy] modernize-use-emplace: Remove unnecessary make_tuple callsJakub Kuderski2017-05-161-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | Summary: This patch makes modernize-use-emplace remove unnecessary make_ calls from push_back calls and turn them into emplace_back -- the same way make_pair calls are handled. Custom make_ calls can be removed for custom tuple-like types -- two new options that control that are `TupleTypes` and `TupleMakeFunctions`. By default, the check removes calls to `std::make_pair` and `std::make_tuple`. Eq. ``` std::vector<std::tuple<int, char, bool>> v; v.push_back(std::make_tuple(1, 'A', true)); // --> v.emplace_back(1, 'A', true); ``` Reviewers: alexfh, aaron.ballman, Prazek, hokein Reviewed By: Prazek Subscribers: JDevlieghere, xazax.hun, JonasToth, cfe-commits Tags: #clang-tools-extra Differential Revision: https://reviews.llvm.org/D32690 llvm-svn: 303139
* [clang-tidy] Fixes to modernize-use-emplacePiotr Padlewski2016-07-291-3/+9
| | | | | | | | Not everything is valid, but it should works for 99.8% cases https://reviews.llvm.org/D22208 llvm-svn: 277097
* [clang-tidy] Add modernize-use-emplacePiotr Padlewski2016-06-211-0/+38
Summary: Add check that replaces call of push_back to emplace_back Reviewers: hokein Differential Revision: http://reviews.llvm.org/D20964 llvm-svn: 273275
OpenPOWER on IntegriCloud