fune/tools/clang-tidy/test/modernize-use-bool-literals.cpp

5 lines
84 B
C++

void foo() {
bool p = 1;
bool f = static_cast<bool>(1);
bool x = p ? 1 : 0;
}