Author: serge-sans-paille Date: 2022-07-05T12:36:00+02:00 New Revision: 3897d3cf71efa50da755e2fc3514b6c2bd4f1433
URL: https://github.com/llvm/llvm-project/commit/3897d3cf71efa50da755e2fc3514b6c2bd4f1433 DIFF: https://github.com/llvm/llvm-project/commit/3897d3cf71efa50da755e2fc3514b6c2bd4f1433.diff LOG: [clang-tidy] By-pass portability issues in confusable-identifiers test Added: Modified: clang-tools-extra/test/clang-tidy/checkers/misc/confusable-identifiers.cpp Removed: ################################################################################ diff --git a/clang-tools-extra/test/clang-tidy/checkers/misc/confusable-identifiers.cpp b/clang-tools-extra/test/clang-tidy/checkers/misc/confusable-identifiers.cpp index 8529d1ef8e8b5..cdfed7edb431d 100644 --- a/clang-tools-extra/test/clang-tidy/checkers/misc/confusable-identifiers.cpp +++ b/clang-tools-extra/test/clang-tidy/checkers/misc/confusable-identifiers.cpp @@ -1,8 +1,8 @@ // RUN: %check_clang_tidy %s misc-confusable-identifiers %t -int fo; -int 𝐟o; -// CHECK-MESSAGES: :[[#@LINE-1]]:5: warning: '𝐟o' is confusable with 'fo' [misc-confusable-identifiers] +int l0; +int lO; +// CHECK-MESSAGES: :[[#@LINE-1]]:5: warning: 'lO' is confusable with 'l0' [misc-confusable-identifiers] // CHECK-MESSAGES: :[[#@LINE-3]]:5: note: other declaration found here void no() { @@ -12,9 +12,9 @@ void no() { void worry() { int foo; } -int 𝐟i; -int fi; -// CHECK-MESSAGES: :[[#@LINE-1]]:5: warning: 'fi' is confusable with '𝐟i' [misc-confusable-identifiers] +int l1; +int ll; +// CHECK-MESSAGES: :[[#@LINE-1]]:5: warning: 'll' is confusable with 'l1' [misc-confusable-identifiers] // CHECK-MESSAGES: :[[#@LINE-3]]:5: note: other declaration found here bool f0(const char *q1, const char *ql) { @@ -55,14 +55,6 @@ void f5(int il) { // CHECK-MESSAGES: :[[#@LINE-3]]:20: note: other declaration found here } -template <typename O0> -void f6() { - int OO = 0; - // CHECK-MESSAGES: :[[#@LINE-1]]:7: warning: 'OO' is confusable with 'O0' [misc-confusable-identifiers] - // CHECK-MESSAGES: :[[#@LINE-4]]:20: note: other declaration found here -} -int OO = 0; // no warning, not same scope as f6 - namespace f7 { int i1; } _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits