| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
| |
The previous matcher "hasAnyTemplateArgument(templateArgument())" only
matches the first template argument, but the check wants to iterate all
template arguments. This patch fixes this.
Also some refactorings in this patch (to make the code reusable).
llvm-svn: 370760
|
|
|
|
|
|
|
|
| |
argument name 'FixDescription' in comment does not match parameter name 'Description'
Patch by Nils Barth!
llvm-svn: 369783
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
Motivation/Context: in the code review system integrating with clang-tidy,
clang-tidy doesn't provide a human-readable description of the fix. Usually
developers have to preview a code diff (before vs after apply the fix) to
understand what the fix does before applying a fix.
This patch proposes that each clang-tidy check provides a short and
actional fix description that can be shown in the UI, so that users can know
what the fix does without previewing diff.
This patch extends clang-tidy framework to support fix descriptions (will add implementations for
existing checks in the future). Fix descriptions and fixes are emitted via diagnostic::Note (rather than
attaching the main warning diagnostic).
Before this patch:
```
void MyCheck::check(...) {
...
diag(loc, "my check warning") << FixtItHint::CreateReplacement(...);
}
```
After:
```
void MyCheck::check(...) {
...
diag(loc, "my check warning"); // Emit a check warning
diag(loc, "fix description", DiagnosticIDs::Note) << FixtItHint::CreateReplacement(...); // Emit a diagnostic note and a fix
}
```
Reviewers: sammccall, alexfh
Reviewed By: alexfh
Subscribers: MyDeveloperDay, Eugene.Zelenko, aaron.ballman, JonasToth, xazax.hun, jdoerfert, cfe-commits
Tags: #clang-tools-extra, #clang
Differential Revision: https://reviews.llvm.org/D59932
llvm-svn: 358576
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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
|
|
|
|
|
|
|
|
| |
Subscribers: nemanjai, ioeric, kbarton, cfe-commits
Differential Revision: https://reviews.llvm.org/D50355
llvm-svn: 339401
|
|
|
|
|
|
|
|
|
|
| |
Reviewers: javed.absar
Subscribers: nemanjai, kbarton, ilya-biryukov, ioeric, jkorous, arphaman, jfb, cfe-commits
Differential Revision: https://reviews.llvm.org/D50354
llvm-svn: 339400
|
|
|
|
|
|
| |
compile errors
llvm-svn: 294578
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
Ran clang-format on all .c/.cpp/.h files in clang-tools-extra.
Excluded the test, unittests, clang-reorder-fields, include-fixer, modularize and pptrace directories.
Reviewers: klimek, alexfh
Subscribers: nemanjai
Tags: #clang-tools-extra
Differential Revision: https://reviews.llvm.org/D26329
llvm-svn: 286221
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
* Fix a false postive when an using class is used in an explicit template instantiation.
* Fix a false postive when an using template class is used as template argument.
Reviewers: aaron.ballman
Subscribers: cfe-commits
Differential Revision: https://reviews.llvm.org/D25437
llvm-svn: 283879
|
|
|
|
|
|
| |
Differential Revision: https://reviews.llvm.org/D24881
llvm-svn: 282319
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
function call expression.
Summary:
The check doesn't mark the template argument as used when the template
argument is a template.
Reviewers: djasper, alexfh
Subscribers: klimek, cfe-commits
Differential Revision: https://reviews.llvm.org/D22803
llvm-svn: 277444
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary: Fix PR28350.
Reviewers: alexfh
Subscribers: aaron.ballman, Eugene.Zelenko, cfe-commits
Differential Revision: http://reviews.llvm.org/D21833
llvm-svn: 274496
|
|
|
|
|
|
|
|
|
|
| |
Reviewers: alexfh, aaron.ballman
Subscribers: aaron.ballman, cfe-commits
Differential Revision: http://reviews.llvm.org/D21747
llvm-svn: 273882
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary: Make the check's behavior more correct when handling using-decls in multiple scopes.
Reviewers: alexfh
Subscribers: cfe-commits
Differential Revision: http://reviews.llvm.org/D20909
llvm-svn: 271632
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
We should check whether a UsingDecl is defined in macros or in class
definition, not TargetDecls of the UsingDecl.
Reviewers: alexfh
Subscribers: cfe-commits
Differential Revision: http://reviews.llvm.org/D20666
llvm-svn: 271199
|
|
|
|
|
|
|
|
|
|
| |
Reviewers: alexfh
Subscribers: cfe-commits, djasper
Differential Revision: http://reviews.llvm.org/D20429
llvm-svn: 270191
|
|
|
|
|
|
|
|
|
|
| |
Reviewers: alexfh, aaron.ballman
Subscribers: aaron.ballman, cfe-commits
Differential Revision: http://reviews.llvm.org/D20367
llvm-svn: 269928
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
misc-unused-using-decls check.
Summary: Ignore warning uninstantiated template function usages.
Reviewers: djasper, alexfh
Subscribers: cfe-commits
Differential Revision: http://reviews.llvm.org/D20326
llvm-svn: 269906
|
|
|
|
|
|
|
|
|
|
|
|
| |
misc-unused-using-decls checks.
Reviewers: djasper
Subscribers: cfe-commits
Differential Revision: http://reviews.llvm.org/D20197
llvm-svn: 269278
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary: Fix PR27429.
Reviewers: djasper
Subscribers: cfe-commits
Differential Revision: http://reviews.llvm.org/D20018
llvm-svn: 268917
|
|
|
|
|
|
| |
This fixes llvm.org/PR27429.
llvm-svn: 266866
|
|
|
|
|
|
|
|
| |
identify things.
This fixes llvm.org/PR27430.
llvm-svn: 266864
|
|
llvm-svn: 266735
|