benilla-re systems structs docs

str_concat

function · lua · boundary

Address
0x7fb830 · 239 bytes, up to 0x7fb91e
Signature
int __fastcall (lua_State *L)
Meaning
Joins the strings of a table range with a separator
Confidence
verified, proof one
Finding
lua/libs#table-library

Finding: Table library in lua: the libraries

Seven of the table functions use the length helpers luaL_getn and luaL_setn. foreachi calls a function on each index up to the length and foreach on each key and value, both ending at the first non-nil result. getn and setn read and set the length, tinsert shifts up and stores, tremove shifts down and answers the removed value, and concat joins strings with a separator. sort runs auxsort, a quicksort over lua_rawgeti and lua_rawseti that compares through sort_comp and swaps with set2.

functionnamedecided by
0x7fb4e0luaB_foreachiluaL_checktype twice, luaL_getn (0x7fb4fc), lua_rawgeti, lua_call (0x7fb552)
0x7fb590luaB_foreachlua_pushnil, lua_next (0x7fb5bb, 0x7fb617), lua_call of three pushes (0x7fb5f1)
0x7fb630luaB_getnluaL_getn (0x7fb64a), lua_pushnumber (0x7fb65d)
0x7fb670luaB_setnluaL_checknumber, __ftol, luaL_setn (0x7fb698)
0x7fb6b0luaB_tinsertluaL_getn (0x7fb6d8), the argument count test (0x7fb6e0), luaL_setn (0x7fb711), shift loop (0x7fb728)
0x7fb770luaB_tremoveluaL_getn (0x7fb78c), luaL_optnumber (0x7fb7a6), luaL_setn (0x7fb7ca), nil stored (0x7fb80a)
0x7fb830str_concatluaL_optlstring (0x7fb84c), luaL_buffinit, table contains non-strings (0x7fb8d1), luaL_pushresult (0x7fb90e)
0x7fb920luaB_sortluaL_getn (0x7fb937), luaL_checkstack (0x7fb94a), auxsort (0x7fb981)
0x7fb990auxsortthree sort_comp and set2 pairs (0x7fb9d4, 0x7fba30, 0x7fba66), the partition loop, invalid order function for sorting
0x7fbc20set2two lua_rawseti (0x7fbc2c, 0x7fbc3c)
0x7fbc50sort_complua_type of the function (0x7fbc5e), lua_call (0x7fbc93), lua_toboolean (0x7fbc9d), lua_lessthan (0x7fbcc0)

The derivation is in the doc.

Callers 0

None by a direct call or jump.

Callees 12

Calls and jumps by a bare address, from tables/calls.tsv.