diff options
author | Zinovy Nis <zinovy.nis@gmail.com> | 2018-04-10 18:05:24 +0000 |
---|---|---|
committer | Zinovy Nis <zinovy.nis@gmail.com> | 2018-04-10 18:05:24 +0000 |
commit | e68c7fa1e55af8ccde6a00f54b980f9f38f549a7 (patch) | |
tree | 53b81b348040194540b160fed3cd63ace78db46b /clang-tools-extra/test/clang-tidy/modernize-use-auto-cast-remove-stars.cpp | |
parent | e3a59e2e91e628a289b74174f3adc4e133855dfa (diff) | |
download | bcm5719-llvm-e68c7fa1e55af8ccde6a00f54b980f9f38f549a7.tar.gz bcm5719-llvm-e68c7fa1e55af8ccde6a00f54b980f9f38f549a7.zip |
[clang-tidy] [modernize-use-auto] Add a threshold for minimal type name length to be replaced with 'auto'
The threshold option is 'MinTypeNameLength' with default value '5'.
With MinTypeNameLength == 5 'int'/'bool' and 'const int'/'const bool'
will not be converted to 'auto', while 'unsigned' will be.
Differential Revision: https://reviews.llvm.org/D45405
llvm-svn: 329730
Diffstat (limited to 'clang-tools-extra/test/clang-tidy/modernize-use-auto-cast-remove-stars.cpp')
-rw-r--r-- | clang-tools-extra/test/clang-tidy/modernize-use-auto-cast-remove-stars.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/clang-tools-extra/test/clang-tidy/modernize-use-auto-cast-remove-stars.cpp b/clang-tools-extra/test/clang-tidy/modernize-use-auto-cast-remove-stars.cpp index c1f2ed8ed97..97b87b8421a 100644 --- a/clang-tools-extra/test/clang-tidy/modernize-use-auto-cast-remove-stars.cpp +++ b/clang-tools-extra/test/clang-tidy/modernize-use-auto-cast-remove-stars.cpp @@ -1,5 +1,5 @@ // RUN: %check_clang_tidy %s modernize-use-auto %t -- \ -// RUN: -config="{CheckOptions: [{key: modernize-use-auto.RemoveStars, value: '1'}]}" \ +// RUN: -config="{CheckOptions: [{key: modernize-use-auto.RemoveStars, value: '1'} , {key: modernize-use-auto.MinTypeNameLength, value: '0'}]}" \ // RUN: -- -std=c++11 -frtti struct A { |