Fix detection of char types

This commit is contained in:
Benoit Blanchon
2022-12-26 10:21:57 +01:00
parent 67abbef818
commit 09f9bd6b8b
3 changed files with 12 additions and 9 deletions

View File

@ -86,6 +86,8 @@ TEST_CASE("custom_string") {
CHECK(s.size() == 5);
}
struct EmptyStruct {};
TEST_CASE("IsString<T>") {
CHECK(IsString<std::string>::value == true);
CHECK(IsString<std::basic_string<wchar_t> >::value == false);
@ -95,6 +97,7 @@ TEST_CASE("IsString<T>") {
CHECK(IsString<const char[8]>::value == true);
CHECK(IsString< ::String>::value == true);
CHECK(IsString< ::StringSumHelper>::value == true);
CHECK(IsString<const EmptyStruct*>::value == false);
}
TEST_CASE("stringCompare") {