fs/Traits, ...: work around -Wtautological-pointer-compare

New in clang 3.6.
This commit is contained in:
Max Kellermann
2014-12-26 14:28:01 +01:00
parent 9f7fd1fbfb
commit 95f84afd33
5 changed files with 32 additions and 1 deletions

View File

@@ -121,8 +121,11 @@ gcc_pure
int
IcuCollate(const char *a, const char *b)
{
#if !CLANG_CHECK_VERSION(3,6)
/* disabled on clang due to -Wtautological-pointer-compare */
assert(a != nullptr);
assert(b != nullptr);
#endif
#ifdef HAVE_ICU
assert(collator != nullptr);
@@ -159,7 +162,10 @@ IcuCaseFold(const char *src)
{
#ifdef HAVE_ICU
assert(collator != nullptr);
#if !CLANG_CHECK_VERSION(3,6)
/* disabled on clang due to -Wtautological-pointer-compare */
assert(src != nullptr);
#endif
const auto u = UCharFromUTF8(src);
if (u.IsNull())