MCPcopy Create free account
hub / github.com/FirebirdSQL/firebird / equals

Method equals

src/common/classes/fb_string.h:813–817  ·  view source on GitHub ↗

These four functions are to speed up the most common comparisons: equality and inequality.

Source from the content-addressed store, hash-verified

811
812 // These four functions are to speed up the most common comparisons: equality and inequality.
813 bool equals(const StringType& str) const
814 {
815 const size_type n = str.length();
816 return (length() != n) ? false : (Comparator::compare(c_str(), str.c_str(), n) == 0);
817 }
818 bool different(const StringType& str) const
819 {
820 const size_type n = str.length();

Callers 2

equivalentMethod · 0.80
parseExternalValueFunction · 0.80

Calls 4

lengthFunction · 0.50
compareClass · 0.50
lengthMethod · 0.45
c_strMethod · 0.45

Tested by

no test coverage detected