Lines Matching refs:pos
298 size_t pos = luaL_optinteger(L, 3, 1) - 1; in b_unpack() local
304 pos += gettoalign(pos, &h, opt, size); in b_unpack()
305 luaL_argcheck(L, pos+size <= ld, 2, "data string too short"); in b_unpack()
311 lua_Number res = getinteger(data+pos, h.endian, issigned, size); in b_unpack()
320 memcpy(&f, data+pos, size); in b_unpack()
327 memcpy(&d, data+pos, size); in b_unpack()
338 luaL_argcheck(L, pos+size <= ld, 2, "data string too short"); in b_unpack()
340 lua_pushlstring(L, data+pos, size); in b_unpack()
344 const char *e = (const char *)memchr(data+pos, '\0', ld - pos); in b_unpack()
347 size = (e - (data+pos)) + 1; in b_unpack()
348 lua_pushlstring(L, data+pos, size - 1); in b_unpack()
353 pos += size; in b_unpack()
355 lua_pushinteger(L, pos + 1); in b_unpack()
363 size_t pos = 0; in b_size() local
368 pos += gettoalign(pos, &h, opt, size); in b_size()
375 pos += size; in b_size()
377 lua_pushinteger(L, pos); in b_size()