#
e3ae0c6f |
| 30-Mar-2016 |
Alexander Kornienko <alexfh@google.com> |
[clang-tidy] readability check for const params in declarations
Summary: Adds a clang-tidy warning for top-level consts in function declarations.
Reviewers: hokein, sbenza, alexfh
Subscribers: cfe
[clang-tidy] readability check for const params in declarations
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
show more ...
|
Revision tags: llvmorg-3.8.0 |
|
#
1612fa07 |
| 25-Feb-2016 |
Alexander Kornienko <alexfh@google.com> |
Add a new check, readability-redundant-string-init, that checks unnecessary string initializations.
Reviewers: hokein, alexfh
Subscribers: cfe-commits
Patch by Shuai Wang!
Differential Revision:
Add a new check, readability-redundant-string-init, that checks unnecessary string initializations.
Reviewers: hokein, alexfh
Subscribers: cfe-commits
Patch by Shuai Wang!
Differential Revision: http://reviews.llvm.org/D17586
llvm-svn: 261939
show more ...
|
Revision tags: llvmorg-3.8.0-rc3, llvmorg-3.8.0-rc2 |
|
#
dde3cd03 |
| 01-Feb-2016 |
Eugene Zelenko <eugene.zelenko@gmail.com> |
Sort checks alphabetically in ReadabilityTidyModule.cpp.
llvm-svn: 259393
|
#
c3975b7d |
| 01-Feb-2016 |
Aaron Ballman <aaron@aaronballman.com> |
Add a new check, readability-redundant-control-flow, that check for some forms of redundant control flow statements. Currently checks for return statements at the end of a function with a void return
Add a new check, readability-redundant-control-flow, that check for some 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
show more ...
|
Revision tags: llvmorg-3.8.0-rc1, llvmorg-3.7.1, llvmorg-3.7.1-rc2, llvmorg-3.7.1-rc1 |
|
#
7f1b5099 |
| 25-Oct-2015 |
Piotr Dziwinski <piotrdz@gmail.com> |
[clang-tidy] Add check readability-implicit-bool-cast
Summary: This is another check that I ported to clang-tidy from colobot-lint tool.
As previously discussed on cfe-dev mailing list, this is one
[clang-tidy] Add check readability-implicit-bool-cast
Summary: This is another check that I ported to clang-tidy from colobot-lint tool.
As previously discussed on cfe-dev mailing list, this is one of those checks that I think is general and useful enough for contribution to clang-tidy.
This patch contains implementation of check taken from colobot-lint, but it is extended a great deal, including FixIt hints for automated refactoring, exhaustive testcases, and user documentation.
Reviewers: sbenza, aaron.ballman, alexfh
Subscribers: Eugene.Zelenko
Differential Revision: http://reviews.llvm.org/D13635
llvm-svn: 251235
show more ...
|
#
daef1631 |
| 19-Oct-2015 |
Samuel Benzaquen <sbenza@google.com> |
Added check uniqueptr-delete-release to replace "delete x.release()" with "x = nullptr"
Reviewers: alexfh
Differential Revision: http://reviews.llvm.org/D13179
llvm-svn: 250742
|
#
11d4d644 |
| 10-Sep-2015 |
Alexander Kornienko <alexfh@google.com> |
[clang-tidy] Add inconsistent declaration parameter name check
This is first of series of patches, porting code from my project colobot-lint, as I mentioned recently in cfe-dev mailing list.
This p
[clang-tidy] Add inconsistent declaration parameter name check
This is first of series of patches, porting code from my project colobot-lint, as I mentioned recently in cfe-dev mailing list.
This patch adds a new check in readability module: readability-inconsistent-declaration-parameter-name. I also added appropriate testcases and documentation.
I chose readability module, as it seems it is the best place for it.
I think I followed the rules of LLVM coding guideline, but I may have missed something, as I usually use other code formatting style.
http://reviews.llvm.org/D12462
Patch by Piotr Dziwinski!
llvm-svn: 247261
show more ...
|
#
0ed6c478 |
| 31-Aug-2015 |
Alexander Kornienko <alexfh@google.com> |
[clang-tidy] Move misc-use-override and readability-shrink-to-fit to "modernize/"
These checks are focusing on migrating the code from C++98/03 to C++11, so they belong to the modernize module.
llv
[clang-tidy] Move misc-use-override and readability-shrink-to-fit to "modernize/"
These checks are focusing on migrating the code from C++98/03 to C++11, so they belong to the modernize module.
llvm-svn: 246437
show more ...
|
Revision tags: llvmorg-3.7.0, llvmorg-3.7.0-rc4, llvmorg-3.7.0-rc3 |
|
#
76c28806 |
| 19-Aug-2015 |
Alexander Kornienko <alexfh@google.com> |
[clang-tidy] Add new IdentifierNaming check
This check will try to enforce coding guidelines on the identifiers naming. It supports lower_case, UPPER_CASE, camelBack and CamelCase casing and tries t
[clang-tidy] Add new IdentifierNaming check
This check will try to enforce coding guidelines on the identifiers naming. It supports lower_case, UPPER_CASE, camelBack and CamelCase casing and tries to convert from one to another if a mismatch is detected.
It also supports a fixed prefix and suffix that will be prepended or appended to the identifiers, regardless of the casing.
Many configuration options are available, in order to be able to create different rules for different kind of identifier. In general, the rules are falling back to a more generic rule if the specific case is not configured.
http://reviews.llvm.org/D10933
Patch by Beren Minor!
llvm-svn: 245429
show more ...
|
Revision tags: studio-1.4, llvmorg-3.7.0-rc2, llvmorg-3.7.0-rc1, llvmorg-3.6.2, llvmorg-3.6.2-rc1, llvmorg-3.6.1, llvmorg-3.6.1-rc1 |
|
#
f5e72b04 |
| 10-Apr-2015 |
Alexander Kornienko <alexfh@google.com> |
[clang-tidy] Add readability-simplify-boolean-expr check to clang-tidy
This check looks for comparisons between boolean expressions and boolean constants and simplifies them to just use the appropri
[clang-tidy] Add readability-simplify-boolean-expr check to clang-tidy
This check looks for comparisons between boolean expressions and boolean constants and simplifies them to just use the appropriate boolean expression directly.
if (b == true) becomes if (b) if (b == false) becomes if (!b) if (b && true) becomes if (b) if (b && false) becomes if (false) if (b || true) becomes if (true) if (b || false) becomes if (b) e ? true : false becomes e e ? false : true becomes !e if (true) t(); else f(); becomes t(); if (false) t(); else f(); becomes f(); if (e) return true; else return false; becomes return (e); if (e) return false; else return true; becomes return !(e); if (e) b = true; else b = false; becomes b = e; if (e) b = false; else b = true; becomes b = !(e);
http://reviews.llvm.org/D7648
Patch by Richard Thomson!
llvm-svn: 234626
show more ...
|
Revision tags: llvmorg-3.5.2, llvmorg-3.5.2-rc1 |
|
#
c5bc68e7 |
| 16-Mar-2015 |
Alexander Kornienko <alexfh@google.com> |
[clang-tidy] Move google-readability-function check to readability-named-parameter.
Summary: The relevant style rule is going to be removed, thus the check is no longer needed in the Google module.
[clang-tidy] Move google-readability-function check to readability-named-parameter.
Summary: The relevant style rule is going to be removed, thus the check is no longer needed in the Google module. Leaving the check in readability/ in case someone needs it.
Reviewers: djasper
Reviewed By: djasper
Subscribers: curdeius, cfe-commits
Differential Revision: http://reviews.llvm.org/D8261
llvm-svn: 232431
show more ...
|
#
57a5c6b5 |
| 16-Mar-2015 |
Alexander Kornienko <alexfh@google.com> |
Move remove-cstr-calls from a standalone executable to a clang-tidy check readability-redundant-string-cstr
http://reviews.llvm.org/D7318
Patch by Richard Thomson!
llvm-svn: 232338
|
#
1b677dbd |
| 09-Mar-2015 |
Alexander Kornienko <alexfh@google.com> |
[clang-tidy] Refactor: Rename clang-tidy readability check files and classes to follow naming conventions
Classes are named WhateverCheck, files are WhateverCheck.cpp and` WhateverCheck.h`
http://r
[clang-tidy] Refactor: Rename clang-tidy readability check files and classes to follow naming conventions
Classes are named WhateverCheck, files are WhateverCheck.cpp and` WhateverCheck.h`
http://reviews.llvm.org/D8144
Patch by Richard Thomson!
llvm-svn: 231650
show more ...
|
Revision tags: llvmorg-3.6.0, llvmorg-3.6.0-rc4, llvmorg-3.6.0-rc3, llvmorg-3.6.0-rc2 |
|
#
e94b7c24 |
| 23-Jan-2015 |
Alexander Kornienko <alexfh@google.com> |
[clang-tidy] Use shrink_to_fit instead of copy and swap trick
The shrink_to_fit() method is more readable and more effective than the copy and swap trick to reduce the capacity of a shrinkable conta
[clang-tidy] Use shrink_to_fit instead of copy and swap trick
The shrink_to_fit() method is more readable and more effective than the copy and swap trick to reduce the capacity of a shrinkable container. Note that, the shrink_to_fit() method is only available in C++11 and up.
Example:
std::vector<int>(v).swap(v); will be replaced with v.shrink_to_fit();
http://reviews.llvm.org/D7087
Patch by Gábor Horváth!
llvm-svn: 226912
show more ...
|
#
4babd689 |
| 15-Jan-2015 |
Alexander Kornienko <alexfh@google.com> |
clang-tidy: 'size' call that could be replaced with 'empty' on STL containers
We are porting some of the checkers at a company we developed to the Clang Tidy infrastructure. We would like to open so
clang-tidy: 'size' call that could be replaced with 'empty' on STL containers
We are porting some of the checkers at a company we developed to the Clang Tidy infrastructure. We would like to open source the checkers that may be useful for the community as well. This patch is the first checker that is being ported to Clang Tidy. We also added fix-it hints, and applied them to LLVM: http://reviews.llvm.org/D6924
The code compiled and the unit tests are passed after the fixits was applied.
The documentation of the checker:
/// The emptiness of a container should be checked using the empty method /// instead of the size method. It is not guaranteed that size is a /// constant-time function, and it is generally more efficient and also shows /// clearer intent to use empty. Furthermore some containers may implement the /// empty method but not implement the size method. Using empty whenever /// possible makes it easier to switch to another container in the future.
It also uses some custom ASTMatchers. In case you find them useful I can submit them as separate patches to clang. I will apply your suggestions to this patch.
http://reviews.llvm.org/D6925
Patch by Gábor Horváth!
llvm-svn: 226172
show more ...
|
Revision tags: llvmorg-3.6.0-rc1 |
|
#
3b6018b9 |
| 14-Jan-2015 |
Daniel Jasper <djasper@google.com> |
clang-tidy: Add initial check for "Don't use else after return".
As per the LLVM coding standards: http://llvm.org/docs/CodingStandards.html#don-t-use-else-after-a-return
Initial version, probably
clang-tidy: Add initial check for "Don't use else after return".
As per the LLVM coding standards: http://llvm.org/docs/CodingStandards.html#don-t-use-else-after-a-return
Initial version, probably still quite a bit to do until this is really useful.
Review: http://reviews.llvm.org/D6927 llvm-svn: 226025
show more ...
|
Revision tags: llvmorg-3.5.1, llvmorg-3.5.1-rc2, llvmorg-3.5.1-rc1 |
|
#
2192a8e5 |
| 26-Oct-2014 |
Alexander Kornienko <alexfh@google.com> |
[clang-tidy] Bring order to check registration.
Summary: Register readability checks in a separate module. Renamed the checks and test file names accordingly.
Reviewers: djasper, klimek
Reviewed B
[clang-tidy] Bring order to check registration.
Summary: Register readability checks in a separate module. Renamed the checks and test file names accordingly.
Reviewers: djasper, klimek
Reviewed By: klimek
Subscribers: curdeius, cfe-commits
Differential Revision: http://reviews.llvm.org/D5936
llvm-svn: 220631
show more ...
|