Files
codeql/cpp/ql/test/library-tests/ir/ir/ir23.cpp
2025-01-16 08:17:57 +01:00

60 lines
683 B
C++

constexpr bool consteval_1() noexcept
{
if consteval {
return true;
} else {
return false;
}
}
constexpr bool consteval_2() noexcept
{
if ! consteval {
return true;
} else {
return false;
}
}
constexpr bool consteval_3() noexcept
{
if consteval {
return true;
}
return false;
}
constexpr bool consteval_4() noexcept
{
if ! consteval {
return true;
}
return false;
}
constexpr bool consteval_5() noexcept
{
bool r = true;
if ! consteval {
r = false;
}
return r;
}
constexpr bool consteval_6() noexcept
{
bool r = true;
if consteval {
r = false;
}
return r;
}
// semmle-extractor-options: -std=c++23