MCPcopy Create free account
hub / github.com/WinMerge/winmerge / matchchar

Function matchchar

Src/stringdiffs.cpp:756–767  ·  view source on GitHub ↗

* @brief Return true if chars match * * Caller must not call this for lead bytes */

Source from the content-addressed store, hash-verified

754 * Caller must not call this for lead bytes
755 */
756static inline bool
757matchchar(const tchar_t *ch1, const tchar_t *ch2, size_t len, bool casitive)
758{
759 if (casitive)
760 return memcmp(ch1, ch2, len * sizeof(tchar_t)) == 0;
761 for (size_t i = 0; i < len; ++i)
762 {
763 if (tc::totlower(ch1[i]) != tc::totlower(ch2[i]))
764 return false;
765 }
766 return true;
767}
768
769
770/** Does character introduce a multicharacter character? */

Callers 1

ComputeByteDiffMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected