MCPcopy Create free account
hub / github.com/BVLC/caffe / CaseInsensitiveCStringEquals

Method CaseInsensitiveCStringEquals

src/gtest/gtest-all.cpp:2899–2905  ·  view source on GitHub ↗

Compares two C strings, ignoring case. Returns true iff they have the same content. Unlike strcasecmp(), this function can handle NULL argument(s). A NULL C string is considered different to any non-NULL C string, including the empty string.

Source from the content-addressed store, hash-verified

2897// NULL C string is considered different to any non-NULL C string,
2898// including the empty string.
2899bool String::CaseInsensitiveCStringEquals(const char * lhs, const char * rhs) {
2900 if (lhs == NULL)
2901 return rhs == NULL;
2902 if (rhs == NULL)
2903 return false;
2904 return posix::StrCaseCmp(lhs, rhs) == 0;
2905}
2906
2907 // Compares two wide C strings, ignoring case. Returns true iff they
2908 // have the same content.

Callers

nothing calls this directly

Calls 1

StrCaseCmpFunction · 0.85

Tested by

no test coverage detected