| 1840 | } |
| 1841 | |
| 1842 | static void lpbD_repeated(lpb_Env *e, const pb_Field *f, uint32_t tag) { |
| 1843 | lua_State *L = e->L; |
| 1844 | if (pb_gettype(tag) != PB_TBYTES |
| 1845 | || (!f->packed && pb_wtypebytype(f->type_id) == PB_TBYTES)) { |
| 1846 | lpbD_field(e, f, tag); |
| 1847 | lua_rawseti(L, -2, (lua_Integer)lua_rawlen(L, -2) + 1); |
| 1848 | } else { |
| 1849 | int len = (int)lua_rawlen(L, -1); |
| 1850 | pb_Slice p, *s = e->s; |
| 1851 | lpb_readbytes(L, s, &p); |
| 1852 | while (p.p < p.end) { |
| 1853 | lpb_withinput(e, &p, lpbD_rawfield(e, f)); |
| 1854 | lua_rawseti(L, -2, ++len); |
| 1855 | } |
| 1856 | } |
| 1857 | } |
| 1858 | |
| 1859 | static int lpbD_message(lpb_Env *e, const pb_Type *t) { |
| 1860 | lua_State *L = e->L; |
no test coverage detected