1// RUN: %check_clang_tidy %s misc-misleading-identifier %t
2
3int printf(const char *format, ...);
4
5// CHECK-MESSAGES: :[[#@LINE+1]]:1: warning: identifier has right-to-left codepoints [misc-misleading-identifier]
6short int א = (short int)0;
7// CHECK-MESSAGES: :[[#@LINE+1]]:1: warning: identifier has right-to-left codepoints [misc-misleading-identifier]
8short int ג = (short int)12345;
9
10int main() {
11 // CHECK-MESSAGES: :[[#@LINE+1]]:3: warning: identifier has right-to-left codepoints [misc-misleading-identifier]
12 int א = ג; // a local variable, set to zero?
13 printf(format: "ג is %d\n", ג);
14 printf(format: "א is %d\n", א);
15}
16

source code of clang-tools-extra/test/clang-tidy/checkers/misc/misleading-identifier.cpp