| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
|
|
|
|
| |
Summary: Fixes PR26595
Reviewers: alexfh
Subscribers: cfe-commits
Differential Revision: http://reviews.llvm.org/D18180
llvm-svn: 265384
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
The clang-tidy documentation generation was broken since commit : http://reviews.llvm.org/D18457
I ran locally the documentation generation and I fixed errors related to that specific check.
Reviewers: alexfh
Subscribers: cfe-commits
Differential Revision: http://reviews.llvm.org/D18764
llvm-svn: 265375
|
|
|
|
|
|
| |
Differential revision: http://reviews.llvm.org/D18717
llvm-svn: 265205
|
|
|
|
|
|
|
|
| |
Fix some checks documentation style.
Differential revision: http://reviews.llvm.org/D18582
llvm-svn: 265072
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
This checker is able to detect missing comma in
an array of string literals.
```
const char* A[] = {
"abc",
"def" // missing comma (no compiler warnings)
"ghi",
};
```
The ratio of false-positive is reduced by restricting the
size of the array considered and the ratio of missing
comma.
To validate the quantity of false positive, the checker
was tried over LLVM and chromium code and detected these
cases:
[[ http://reviews.llvm.org/D18454 | http://reviews.llvm.org/D18454 ]]
[[https://codereview.chromium.org/1807753002/ | https://codereview.chromium.org/1807753002/]]
[[https://codereview.chromium.org/1826193002/ | https://codereview.chromium.org/1826193002/]]
[[https://codereview.chromium.org/1805713002/ | https://codereview.chromium.org/1805713002/]]
Reviewers: alexfh
Subscribers: LegalizeAdulthood, szdominik, xazax.hun, cfe-commits
Differential Revision: http://reviews.llvm.org/D18457
llvm-svn: 265033
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary: Adds a clang-tidy warning for top-level consts in function declarations.
Reviewers: hokein, sbenza, alexfh
Subscribers: cfe-commits
Patch by Matt Kulukundis!
Differential Revision: http://reviews.llvm.org/D18408
llvm-svn: 264856
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
Add check misc-dangling-handle to detect dangling references in value
handlers like std::experimental::string_view.
It provides a configuration option to specify other handle types that
should also be checked.
Right now it detects:
- Construction from temporaries.
- Assignment from temporaries.
- Return statements from temporaries or locals.
- Insertion into containers from temporaries.
Reviewers: alexfh
Subscribers: cfe-commits
Differential Revision: http://reviews.llvm.org/D17811
llvm-svn: 264759
|
|
|
|
|
|
|
|
|
|
|
|
| |
to copy types that can be safely converted to const references.
Reviewers: alexfh
Subscribers: fowles, cfe-commits
Differential Revision: http://reviews.llvm.org/D17491
llvm-svn: 264694
|
|
|
|
| |
llvm-svn: 264539
|
|
|
|
| |
llvm-svn: 264531
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary: Extends the UnnecessaryCopyInitialization to detect copies of local variables and parameters that are unneeded.
Patch by Matt Kulukundis!
Reviewers: alexfh, hokein
Subscribers: cfe-commits
Differential Revision: http://reviews.llvm.org/D18149
llvm-svn: 264146
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
non-const copies that can be safely converted to const references.
Summary:
Move code shared between UnnecessaryCopyInitialization and ForRangeCopyCheck into utilities files.
Add more test cases for UnnecessaryCopyInitialization and disable fixes inside of macros.
Reviewers: alexfh
Subscribers: cfe-commits
Differential Revision: http://reviews.llvm.org/D17488
llvm-svn: 262781
|
|
|
|
| |
llvm-svn: 262655
|
|
|
|
| |
llvm-svn: 262654
|
|
|
|
|
|
| |
compilation fails.
llvm-svn: 262615
|
|
|
|
| |
llvm-svn: 262601
|
|
|
|
| |
llvm-svn: 261998
|
|
|
|
| |
llvm-svn: 261940
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
string initializations.
Reviewers: hokein, alexfh
Subscribers: cfe-commits
Patch by Shuai Wang!
Differential Revision: http://reviews.llvm.org/D17586
llvm-svn: 261939
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary: Because of the recent Google Code shutdown links to the Google Code Style up there are no longer relevant.
Reviewers: alexfh, hokein
Subscribers: cfe-commits
Patch by Kirill Bobyrev!
Differential Revision: http://reviews.llvm.org/D17602
llvm-svn: 261868
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
This patch introduces the modernize-deprecated-headers check, which is supposed to replace deprecated C library headers with the C++ STL-ones.
For information see documentation; for exmaples see the test cases.
Reviewers: Eugene.Zelenko, LegalizeAdulthood, alexfh
Subscribers: cfe-commits
Patch by Kirill Bobyrev!
Differential Revision: http://reviews.llvm.org/D17484
llvm-svn: 261738
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
namespace
Adds a new check "misc-forward-declaration-namespace".
In check, A forward declaration is considerred in a potentially wrong namespace
if there is any definition/declaration with the same name exists in a different
namespace.
Reviewers: akuegel, hokein, alexfh
Patch by Eric Liu!
Differential Revision: http://reviews.llvm.org/D17195
llvm-svn: 261737
|
|
|
|
| |
llvm-svn: 261622
|
|
|
|
|
|
| |
_popen() to execute a command processor. This check corresponds to the CERT secure coding rule: https://www.securecoding.cert.org/confluence/pages/viewpage.action?pageId=2130132
llvm-svn: 261530
|
|
|
|
|
|
| |
updates
llvm-svn: 261431
|
|
|
|
|
|
| |
floating-point type. This check corresponds to the CERT secure coding rule: https://www.securecoding.cert.org/confluence/display/c/FLP30-C.+Do+not+use+floating-point+variables+as+loop+counters
llvm-svn: 261324
|
|
|
|
| |
llvm-svn: 260912
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
This patch is a continuation of http://reviews.llvm.org/D10553 by Jonathan B Coe.
The main additions are:
1. For C++11 the check suggests in-class field initialization as fix. This
makes the fields future proof towards the addition of new constructors.
2 For older language versions the fields are added in the right position
in the initializer list with more tests.
3. User documentation.
Reviewers: alexfh, jbcoe
Subscribers: cfe-commits
Differential Revision: http://reviews.llvm.org/D16517
llvm-svn: 260873
|
|
|
|
| |
llvm-svn: 260869
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
Add check performance-faster-string-find.
It replaces single character string literals to character literals in calls to string::find and friends.
Reviewers: alexfh
Subscribers: cfe-commits
Differential Revision: http://reviews.llvm.org/D16152
llvm-svn: 260712
|
|
|
|
|
|
|
|
|
|
|
|
| |
Expand the simplify boolean expression check to handle implicit conversion of integral types to bool and improve the handling of implicit conversion of member pointers to bool.
Implicit conversion of member pointers are replaced with explicit comparisons to nullptr.
Implicit conversions of integral types are replaced with explicit comparisons to 0.
Patch by Richard Thomson.
llvm-svn: 260681
|
|
|
|
|
|
|
|
|
|
| |
semantics.
Reviewers: hokein, alexfh
Differential Revision: http://reviews.llvm.org/D16535
llvm-svn: 260503
|
|
|
|
|
|
|
|
|
|
| |
Reviewers: alexfh
Subscribers: cfe-commits
Differential Revision: http://reviews.llvm.org/D16310
llvm-svn: 260223
|
|
|
|
|
|
|
|
|
|
| |
Reviewers: alexfh
Subscribers: cfe-commits
Differential Revision: http://reviews.llvm.org/D16926
llvm-svn: 260107
|
|
|
|
| |
llvm-svn: 260100
|
|
|
|
| |
llvm-svn: 260099
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary: We have 2 scripts add_new_check.py and rename_check.py to bootstrap a new check creation. There is also clang-query to aid with the matcher creation. These were not mentioned in the current document, add them so it's available to the masses.
Reviewers: alexfh
Patch by Deniz Türkoglu!
Differential Revision: http://reviews.llvm.org/D16944
llvm-svn: 260098
|
|
|
|
|
|
|
| |
http://bb.pgr.jp/builders/cmake-clang-tools-x86_64-linux/builds/23351
http://lab.llvm.org:8011/builders/clang-s390x-linux/builds/492
llvm-svn: 260097
|
|
|
|
|
|
|
|
|
|
|
|
| |
of integral types to bool and improve the handling of implicit conversion of member pointers to bool.
Implicit conversion of member pointers are replaced with explicit comparisons to nullptr.
Implicit conversions of integral types are replaced with explicit comparisons to 0.
Patch by Richard Thomson.
llvm-svn: 260096
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary: This is originally implemented by Jacques Pienaar.
Reviewers: alexfh
Subscribers: cfe-commits, jpienaar
Differential Revision: http://reviews.llvm.org/D16764
llvm-svn: 260084
|
|
|
|
| |
llvm-svn: 260065
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary: This is implemented originally by Alexander Kornienko.
Reviewers: alexfh
Subscribers: cfe-commits
Patch by Haojian Wu!
Differential Revision: http://reviews.llvm.org/D16717
llvm-svn: 259530
|
|
|
|
|
|
|
|
| |
forms of redundant control flow statements. Currently checks for return statements at the end of a function with a void return type and continue statements at the end of looping statements.
Patch by Richard Thomson.
llvm-svn: 259362
|
|
|
|
|
|
|
|
|
|
| |
loop variables.
Patch by Felix Berger!
Differential revision: http://reviews.llvm.org/D13849
llvm-svn: 259199
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary: "checkParamTypes" may fail if the the type of some parameter is not canonical. Fixed it by comparing canonical types. And added "getCanonicalType()" and "getCanonicalDecl()" on more places to prevent potential fail.
Reviewers: alexfh
Subscribers: cfe-commits
Patch by Cong Liu!
Differential Revision: http://reviews.llvm.org/D16587
llvm-svn: 259197
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary: This is implemented originally by Alex Pilkiewicz (pilki@google.com).
Reviewers: alexfh
Subscribers: cfe-commits
Patch by Haojian Wu!
Differential Revision: http://reviews.llvm.org/D16721
llvm-svn: 259195
|
|
|
|
|
|
|
|
|
|
| |
Fixed broken links to cppcoreguidelines (anchors specified in the .md file
should be used, not automatic anchors generated by github).
Fixed formatting, array_view -> span, fixed sphinx errors in
misc-definitions-in-headers.rst.
llvm-svn: 258926
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
This patch fixes shebang lines in Python script files.
Most Python scripts in LLVM & Clang are using this shebang line.
[[ https://mail.python.org/pipermail/tutor/2007-June/054816.html | Here]] is an explanaiton of why such line should be used instead of what is currently in these few files.
Reviewers: klimek, alexfh
Subscribers: cfe-commits
Patch by Kirill Bobyrev!
Differential Revision: http://reviews.llvm.org/D16270
llvm-svn: 258133
|
|
|
|
| |
llvm-svn: 258098
|
|
|
|
|
|
|
|
|
| |
Similar in format to the `-checks=` argument, this new `-warnings-as-errors=`
argument upgrades any warnings emitted by the former to errors.
http://reviews.llvm.org/D15528
llvm-svn: 257642
|