| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
...
This check verifies if a buffer passed to an MPI (Message Passing Interface)
function is sufficiently dereferenced. Buffers should be passed as a single
pointer or array. As MPI function signatures specify void * for their buffer
types, insufficiently dereferenced buffers can be passed, like for example
as double pointers or multidimensional arrays, without a compiler warning
emitted.
Instructions on how to apply the check can be found at:
https://github.com/0ax1/MPI-Checker/tree/master/examples
Reviewers: Haojian Wu
Differential revision: https://reviews.llvm.org/D22729
llvm-svn: 278553
|
|
|
|
|
|
| |
Mention Clang-rename Emacs integration in release notes.
llvm-svn: 278295
|
|
|
|
|
|
| |
readability-else-after-return description spotted by Alexander Kornienko.
llvm-svn: 278279
|
|
|
|
|
|
| |
Clang-tidy readability-else-after-return description.
llvm-svn: 278263
|
|
|
|
| |
llvm-svn: 278262
|
|
|
|
|
|
|
|
|
|
|
|
| |
`readability-else-after-return` only warns about `return` calls, but LLVM Coding
Standars stat that `throw`, `continue`, `goto`, etc after `return` calls are
bad, too.
Reviwers: alexfh, aaron.ballman
Differential Revision: https://reviews.llvm.org/D23265
llvm-svn: 278257
|
|
|
|
|
|
| |
Alexander Kornienko.
llvm-svn: 278255
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch introduces a minor list of changes as proposed by Richard Smith in
the mailing list.
See original comments with an impact on the future check state below:
[comments.begin
> + {"complex.h", "ccomplex"},
It'd be better to convert this one to <complex>, or leave it alone.
<ccomplex> is an unnecessary wart.
(The contents of C++11's <complex.h> / <ccomplex> / <complex> (all of
which are identical) aren't comparable to C99's <complex.h>, so if
this was C++98 code using the C99 header, the code will be broken with
or without this transformation.)
> + {"iso646.h", "ciso646"},
Just delete #includes of this one. <ciso646> does nothing.
> + {"stdalign.h", "cstdalign"},
> + {"stdbool.h", "cstdbool"},
We should just delete these two includes. These headers do nothing in C++.
comments.end]
Reviewers: alexfh, aaron.ballman
Differential Revision: https://reviews.llvm.org/D17990
llvm-svn: 278254
|
|
|
|
| |
llvm-svn: 278201
|
|
|
|
| |
llvm-svn: 278198
|
|
|
|
|
|
|
|
|
|
|
| |
This is handy in case by the time clang-rename is invoked, an external
tool already genereated a list of oldname -> newname pairs to handle.
Reviewers: omtcyfz
Differential Revision: https://reviews.llvm.org/D23198
llvm-svn: 278145
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
modernize-use-bool-literals doesn't checks operands in ternary operator.
For example:
``` c++
static int Value = 1;
bool foo() {
bool Result = Value == 1 ? 1 : 0;
return Result;
}
bool boo() {
return Value == 1 ? 1 : 0;
}
```
This issue was reported in bug 28854. The patch fixes it.
Reviewers: alexfh, aaron.ballman, Prazek
Subscribers: Prazek, Eugene.Zelenko
Differential Revision: https://reviews.llvm.org/D23243
llvm-svn: 278022
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
The misc-argument-comment check now ignores leading and trailing underscores and
case. The new `StrictMode` local/global option can be used to switch back to
strict checking.
Add getLocalOrGlobal version for integral types, minor cleanups.
Reviewers: hokein, aaron.ballman
Subscribers: aaron.ballman, Prazek, cfe-commits
Differential Revision: https://reviews.llvm.org/D23135
llvm-svn: 277729
|
|
|
|
|
|
|
|
| |
Patch by Bittner Barni!
Differential revision: https://reviews.llvm.org/D20196
llvm-svn: 277677
|
|
|
|
|
|
| |
clang-rename is a refactoring tool, not "linter" tool. Fix typo in docs.
llvm-svn: 277623
|
|
|
|
|
|
|
|
|
|
| |
alexfh raised a concern with https://reviews.llvm.org/rL277340
After retabbing indentation of .. code-block:: was increased to 8, 4 spaces
indentation should be enough.
Reviewers: alexfh
llvm-svn: 277577
|
|
|
|
| |
llvm-svn: 277517
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This check verifies if buffer type and MPI (Message Passing Interface)
datatype pairs match. All MPI datatypes defined by the MPI standard (3.1)
are verified by this check. User defined typedefs, custom MPI datatypes and
null pointer constants are skipped, in the course of verification.
Instructions on how to apply the check can be found at:
https://github.com/0ax1/MPI-Checker/tree/master/examples
Patch by Alexander Droste!
Differential revision: https://reviews.llvm.org/D21962
llvm-svn: 277516
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- rename-at is meant to be integrated with editors and works mainly off
of a location in a file, and this is the default
- rename-all is optimized for one or more oldname->newname renames, and
works with clang-apply-replacements
Reviewers: bkramer, klimek
Subscribers: omtcyfz
Differential Revision: https://reviews.llvm.org/D21814
llvm-svn: 277438
|
|
|
|
|
|
|
|
|
|
| |
This patch aims to add very basic Emacs integration.
Reviewers: hokein, alexfh
Differential Revision: https://reviews.llvm.org/D23006
llvm-svn: 277433
|
|
|
|
| |
llvm-svn: 277340
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
Check for classes that violate the rule of five and zero as specified in CppCoreGuidelines:
"If a class defines or deletes a default operation then it should define or delete them all."
https://github.com/isocpp/CppCoreGuidelines/blob/master/CppCoreGuidelines.md#c21-if-you-define-or-delete-any-default-operation-define-or-delete-them-all.
Reviewers: alexfh, sbenza, aaron.ballman
Subscribers: Prazek, Eugene.Zelenko, cfe-commits, ericLemanissier, nemanjai
Projects: #clang-tools-extra
Differential Revision: https://reviews.llvm.org/D22513
llvm-svn: 277262
|
|
|
|
|
|
|
|
| |
Not everything is valid, but it should works for 99.8% cases
https://reviews.llvm.org/D22208
llvm-svn: 277097
|
|
|
|
| |
llvm-svn: 276871
|
|
|
|
|
|
|
|
|
|
|
|
| |
Change Vim key binding for include-fixer (`,cf` -> `<leader>cf`) and
clang-rename (`,cr` -> `<leader>cr`) to use `<leader>` instead of `,` like
cool Vim people (tm) do.
Reviewers: ioeric
Differential Revision: https://reviews.llvm.org/D22854
llvm-svn: 276870
|
|
|
|
| |
llvm-svn: 276862
|
|
|
|
| |
llvm-svn: 276861
|
|
|
|
|
|
|
|
| |
Patch by Jens Massberg! Thanks a lot.
Differential Revision: https://reviews.llvm.org/D22805
llvm-svn: 276853
|
|
|
|
|
|
| |
This reverts commit r276640. Breaks multiple buildbots.
llvm-svn: 276651
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
This check verifies if buffer type and MPI (Message Passing Interface)
datatype pairs match. All MPI datatypes defined by the MPI standard (3.1)
are verified by this check. User defined typedefs, custom MPI datatypes and
null pointer constants are skipped, in the course of verification.
Instructions on how to apply the check can be found at: https://github.com/0ax1/MPI-Checker/tree/master/examples
Reviewers: alexfh
Subscribers: cfe-commits
Projects: #clang-tools-extra
Patch by Alexander Droste!
Differential Revision: https://reviews.llvm.org/D21962
llvm-svn: 276640
|
|
|
|
|
|
| |
Second try for r276408
llvm-svn: 276415
|
|
|
|
|
|
| |
Tests fail on clang-x64-ninja-win7 due to too narrow expectation.
llvm-svn: 276413
|
|
|
|
|
|
|
|
|
|
|
|
| |
Flags slicing of member variables or vtable. See:
https://github.com/isocpp/CppCoreGuidelines/blob/master/CppCoreGuidelines.md#es63-dont-slice
https://github.com/isocpp/CppCoreGuidelines/blob/master/CppCoreGuidelines.md#c145-access-polymorphic-objects-through-pointers-and-references
Differential revision:
http://reviews.llvm.org/D21974
llvm-svn: 276408
|
|
|
|
|
|
| |
Differential revision: https://reviews.llvm.org/D22605
llvm-svn: 276371
|
|
|
|
| |
llvm-svn: 275849
|
|
|
|
|
|
| |
The 3.9 release are on the 3.9 branch.
llvm-svn: 275846
|
|
|
|
|
|
|
|
|
|
|
| |
clang-rename needs at least to have a minimum documentation to provide a
small introduction for new users
Patch by Kirill Bobyrev!
Differential Revision: http://reviews.llvm.org/D22129
llvm-svn: 275388
|
|
|
|
| |
llvm-svn: 275254
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
value parameter can be moved.
Summary:
Make check more useful in the following two cases:
The parameter is passed by non-const value, has a non-deleted move constructor and is only referenced once in the function as argument to the type's copy constructor.
The parameter is passed by non-const value, has a non-deleted move assignment operator and is only referenced once in the function as argument of the the type's copy assignment operator.
In this case suggest a fix to move the parameter which avoids the unnecessary copy and is closest to what the user might have intended.
Reviewers: alexfh, sbenza
Subscribers: cfe-commits, Prazek
Differential Revision: http://reviews.llvm.org/D20277
llvm-svn: 274380
|
|
|
|
|
|
| |
http://reviews.llvm.org/D18919
llvm-svn: 273786
|
|
|
|
|
|
|
|
|
|
| |
Summary: Add check that replaces call of push_back to emplace_back
Reviewers: hokein
Differential Revision: http://reviews.llvm.org/D20964
llvm-svn: 273275
|
|
|
|
| |
llvm-svn: 272994
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
Added support for macro definitions.
--
1. Added a pre-processor callback to catch macro definitions
2. Changed the type of the failure map so that macros and declarations can share the same map
3. Added extra tests to ensure fix-ups work using the new map
4. Added fix-ups for type aliases in variable and function declarations as part of adding the new tests
Reviewers: alexfh
Subscribers: Eugene.Zelenko, cfe-commits
Patch by James Reynolds!
Differential Revision: http://reviews.llvm.org/D21020
llvm-svn: 272993
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
passed as a const ref argument
Summary:
Conceptually, this is very close to the existing functionality of misc-move-const-arg, which is why I'm adding it here and not creating a new check. For example, for a type A that is both movable and copyable, this
const A a1;
A a2(std::move(a1));
is not only a case where a const argument is being passed to std::move(), but the result of std::move() is also being passed as a const reference (due to overload resolution).
The new check typically triggers (exclusively) in cases where people think they're dealing with a movable type, but in fact the type is not movable.
Reviewers: hokein, aaron.ballman, alexfh
Subscribers: aaron.ballman, cfe-commits
Patch by Martin Boehme!
Differential Revision: http://reviews.llvm.org/D21223
llvm-svn: 272896
|
|
|
|
|
|
| |
Highlight return statement in misc-unconventional-assign-operator documentation.
llvm-svn: 272042
|
|
|
|
| |
llvm-svn: 272038
|
|
|
|
| |
llvm-svn: 272026
|
|
|
|
|
|
| |
const-qualifier is applied to a typedef of pointer type rather than to the pointee type.
llvm-svn: 272025
|
|
|
|
|
|
|
|
|
|
| |
Reviewers: bkramer
Subscribers: Eugene.Zelenko, cfe-commits, ioeric
Differential Revision: http://reviews.llvm.org/D20467
llvm-svn: 271989
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
By default, modernize-use-auto check will retain stars when replacing an explicit type with `auto`: `MyType *t = new MyType;` will be changed to `auto *t = new MyType;`, thus resulting in more consistency with the recommendations to use `auto *` for iterating over pointers in range-based for loops: http://llvm.org/docs/CodingStandards.html#beware-unnecessary-copies-with-auto
The new `RemoveStars` option allows to revert to the old behavior: with the new option turned on the check will change `MyType *t = new MyType;` to `auto t = new MyType;`.
Reviewers: aaron.ballman, sbenza
Subscribers: Eugene.Zelenko, cfe-commits
Differential Revision: http://reviews.llvm.org/D20917
llvm-svn: 271739
|