… | |
… | |
164 | |
164 | |
165 | HV *self; // CF+ perl self |
165 | HV *self; // CF+ perl self |
166 | AV *cb; // CF+ callbacks |
166 | AV *cb; // CF+ callbacks |
167 | shstr attach; // generic extension attachment information |
167 | shstr attach; // generic extension attachment information |
168 | |
168 | |
|
|
169 | void sever_self (); // sever this object from its self, if it has one. |
169 | void optimise (); // possibly save some memory by destroying unneeded data |
170 | void optimise (); // possibly save some memory by destroying unneeded data |
170 | |
171 | |
171 | attachable () |
172 | attachable () |
172 | : flags (0), refcnt (0), self (0), cb (0), attach (0) |
173 | : flags (0), refcnt (0), self (0), cb (0), attach (0) |
173 | { |
174 | { |
174 | } |
175 | } |
… | |
… | |
339 | |
340 | |
340 | struct object_thawer |
341 | struct object_thawer |
341 | { |
342 | { |
342 | SV *text; // text part |
343 | SV *text; // text part |
343 | AV *av; // perl part |
344 | AV *av; // perl part |
|
|
345 | int linenum; |
344 | char *line; // current beginning of line |
346 | char *line; // current beginning of line |
345 | char *last_keyword, *last_value; |
347 | char *last_keyword, *last_value; |
346 | const char *name; |
348 | const char *name; |
347 | |
349 | |
348 | operator bool () { return !!text; } |
350 | operator bool () { return !!text; } |
… | |
… | |
376 | void get (uint16 &i) { i = get_sint32 (); } |
378 | void get (uint16 &i) { i = get_sint32 (); } |
377 | void get (sint32 &i) { i = get_sint32 (); } |
379 | void get (sint32 &i) { i = get_sint32 (); } |
378 | |
380 | |
379 | void get (uint32 &i) { i = get_sint64 (); } |
381 | void get (uint32 &i) { i = get_sint64 (); } |
380 | void get (sint64 &i) { i = get_sint64 (); } |
382 | void get (sint64 &i) { i = get_sint64 (); } |
381 | }; |
|
|
382 | |
383 | |
|
|
384 | bool parse_error (keyword kw, const char *type = 0, const char *name = 0, bool skip = true); |
|
|
385 | }; |
|
|
386 | |
|
|
387 | //TODO: remove |
383 | char *fgets (char *s, int n, object_thawer &thawer); |
388 | char *fgets (char *s, int n, object_thawer &thawer); |
384 | |
389 | |
385 | ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// |
390 | ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// |
386 | |
391 | |
387 | struct coroapi { |
392 | struct coroapi { |