| 241 | |
| 242 | |
| 243 | static void LoadFunction(LoadState *S, Proto *f, TString *psource) { |
| 244 | f->source = LoadString(S); |
| 245 | if (f->source == nullptr) /* no source in dump? */ |
| 246 | f->source = psource; /* reuse parent's source */ |
| 247 | f->linedefined = LoadInt(S); |
| 248 | f->lastlinedefined = LoadInt(S); |
| 249 | f->numparams = LoadByte(S); |
| 250 | f->is_vararg = LoadByte(S); |
| 251 | f->maxstacksize = LoadByte(S); |
| 252 | |
| 253 | if (!LoadCode(S, f)) |
| 254 | { |
| 255 | return; |
| 256 | } |
| 257 | |
| 258 | if (!LoadConstants(S, f)) |
| 259 | { |
| 260 | return; |
| 261 | } |
| 262 | |
| 263 | if (!LoadUpvalues(S, f)) |
| 264 | { |
| 265 | return; |
| 266 | } |
| 267 | |
| 268 | if (!LoadProtos(S, f)) |
| 269 | { |
| 270 | return; |
| 271 | } |
| 272 | |
| 273 | LoadDebug(S, f); |
| 274 | } |
| 275 | |
| 276 | |
| 277 | static void checkliteral(LoadState *S, const char *s, const char *msg) { |
no test coverage detected