|
|
@ -85,6 +85,18 @@ struct ink_routine { |
|
|
|
void *routine_userdata; |
|
|
|
}; |
|
|
|
|
|
|
|
struct ink_collection_list { |
|
|
|
struct elem* elems; |
|
|
|
size_t size; |
|
|
|
}; |
|
|
|
|
|
|
|
struct ink_type { |
|
|
|
const char* name; |
|
|
|
void* elements; |
|
|
|
void (*collect)(void*); |
|
|
|
struct ink_collection_list (*gc)(void*); |
|
|
|
}; |
|
|
|
|
|
|
|
/** |
|
|
|
* Represents a complete execution context for the ink interpreter |
|
|
|
*/ |
|
|
@ -99,6 +111,10 @@ struct context { |
|
|
|
struct ink_routine *routines; |
|
|
|
int routines_capacity; |
|
|
|
int routines_top; |
|
|
|
|
|
|
|
struct ink_type *types; |
|
|
|
int types_capacity; |
|
|
|
int types_top; |
|
|
|
|
|
|
|
/** |
|
|
|
* Contains the id of the routine that is currently being manipulated |
|
|
|