23 TEST(ConstexprTest, constexpr_strlen_cstr) {
24 constexpr
auto v =
"hello";
31 #if !(defined(__GNUC__) && !defined(__clang__) && __GNUC__ < 5) 32 TEST(ConstexprTest, constexpr_strlen_ints) {
33 constexpr
int v[] = {5, 3, 4, 0, 7};
39 TEST(ConstexprTest, constexpr_strcmp_ints) {
40 constexpr
int v[] = {5, 3, 4, 0, 7};
41 constexpr
int v1[] = {6, 4};
49 "constexpr_strcmp is broken");
51 static_assert(
constexpr_strcmp(
"abc",
"def") < 0,
"constexpr_strcmp is broken");
52 static_assert(
constexpr_strcmp(
"xyz",
"abc") > 0,
"constexpr_strcmp is broken");
53 static_assert(
constexpr_strcmp(
"a",
"abc") < 0,
"constexpr_strcmp is broken");
54 static_assert(
constexpr_strcmp(
"abc",
"a") > 0,
"constexpr_strcmp is broken");
TEST(ConstexprTest, constexpr_strlen_cstr)
#define EXPECT_EQ(val1, val2)
constexpr int constexpr_strcmp(const Char *s1, const Char *s2)
static const char *const value
#define EXPECT_TRUE(condition)
constexpr size_t constexpr_strlen(const Char *s)