MCPcopy Create free account
hub / github.com/Tencent/sluaunreal / luaS_eqlngstr

Function luaS_eqlngstr

Plugins/slua_unreal/External/lua/lstring.cpp:39–45  ·  view source on GitHub ↗

** equality for long strings */

Source from the content-addressed store, hash-verified

37** equality for long strings
38*/
39int luaS_eqlngstr (TString *a, TString *b) {
40 size_t len = a->u.lnglen;
41 lua_assert(a->tt == LUA_TLNGSTR && b->tt == LUA_TLNGSTR);
42 return (a == b) || /* same instance or... */
43 ((len == b->u.lnglen) && /* equal length and ... */
44 (memcmp(getstr(a), getstr(b), len) == 0)); /* equal contents */
45}
46
47
48unsigned int luaS_hash (const char *str, size_t l, unsigned int seed) {

Callers 1

luaV_equalobjFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected