MCPcopy Create free account
hub / github.com/EmmyLua/EmmyLuaDebugger / copy2buff

Function copy2buff

third-party/lua-5.4.6/src/lvm.c:631–639  ·  view source on GitHub ↗

copy strings in stack from top - n up to top - 1 to buffer */

Source from the content-addressed store, hash-verified

629
630/* copy strings in stack from top - n up to top - 1 to buffer */
631static void copy2buff (StkId top, int n, char *buff) {
632 size_t tl = 0; /* size already copied */
633 do {
634 TString *st = tsvalue(s2v(top - n));
635 size_t l = tsslen(st); /* length of string being copied */
636 memcpy(buff + tl, getstr(st), l * sizeof(char));
637 tl += l;
638 } while (--n > 0);
639}
640
641
642/*

Callers 1

luaV_concatFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected