Mercurial > repos > rhope
comparison runtime/object.h @ 56:d2f9b0a9403d
Initial experiment with goto and switch
author | Mike Pavone <pavone@retrodev.com> |
---|---|
date | Thu, 08 Oct 2009 01:52:38 -0400 |
parents | 495dddadd058 |
children | b218af069da7 |
comparison
equal
deleted
inserted
replaced
38:7f05bbe82f24 | 56:d2f9b0a9403d |
---|---|
13 rhope_func *convert_from; | 13 rhope_func *convert_from; |
14 special_func init; | 14 special_func init; |
15 special_func copy; | 15 special_func copy; |
16 special_func cleanup; | 16 special_func cleanup; |
17 struct object *name; | 17 struct object *name; |
18 uint32_t type_id; | |
18 uint32_t first_methodid; | 19 uint32_t first_methodid; |
19 uint32_t last_methodid; | 20 uint32_t last_methodid; |
20 uint32_t first_getfieldid; | 21 uint32_t first_getfieldid; |
21 uint32_t last_getfieldid; | 22 uint32_t last_getfieldid; |
22 uint32_t first_setfieldid; | 23 uint32_t first_setfieldid; |
37 typedef struct { | 38 typedef struct { |
38 object base; | 39 object base; |
39 uint32_t size; | 40 uint32_t size; |
40 } multisize; | 41 } multisize; |
41 | 42 |
42 | 43 #pragma pack(push,1) |
43 typedef struct calldata { | 44 typedef struct calldata { |
44 rhope_func tail_func; | 45 object *params[1]; |
45 struct context *ct; | 46 struct calldata *lastframe; |
46 void *locals; | 47 uint16_t num_params; |
47 struct calldata *call; | 48 uint16_t resume; |
48 uint32_t original_methodid; | 49 uint32_t func; |
49 uint16_t num_params; | |
50 uint16_t resume; | |
51 object *params[1]; | |
52 } calldata; | 50 } calldata; |
51 #pragma pack(pop) | |
53 | 52 |
54 #define OBegin typedef struct { object header; | 53 #define OBegin typedef struct { object header; |
55 #define Object(name) } t_ ## name; | 54 #define Object(name) } t_ ## name; |
56 | 55 |
57 #define MOBegin typedef struct { multisize header; | 56 #define MOBegin typedef struct { multisize header; |