|
Reduct
v1.0.4-3-gdaf0d70
A functional and immutable language.
|
Compiled function. More...
Go to the source code of this file.
Data Structures | |
| struct | reduct_const_slot_t |
| Constant slot. More... | |
| struct | reduct_function_t |
| Compiled function structure. More... | |
Macros | |
| #define | REDUCT_CONST_SLOT_ITEM(_item) ((reduct_const_slot_t){.type = REDUCT_CONST_SLOT_ITEM, .item = (_item)}) |
| Create a constant slot containing an item. | |
| #define | REDUCT_CONST_SLOT_CAPTURE(_capture) ((reduct_const_slot_t){.type = REDUCT_CONST_SLOT_CAPTURE, .capture = (_capture)}) |
| Create a constant slot containing a variable name to be captured. | |
Typedefs | |
| typedef reduct_uint16_t | reduct_const_t |
| Constant index type. | |
Enumerations | |
| enum | reduct_const_slot_type_t { REDUCT_CONST_SLOT_NONE , REDUCT_CONST_SLOT_ITEM , REDUCT_CONST_SLOT_CAPTURE } |
| Constant slot type. More... | |
Functions | |
| REDUCT_API void | reduct_function_init (reduct_function_t *func) |
| Initialize a function structure. | |
| REDUCT_API void | reduct_function_deinit (reduct_function_t *func) |
| Deinitialize a function structure. | |
| REDUCT_API reduct_function_t * | reduct_function_new (struct reduct *reduct) |
| Create a new function. | |
| REDUCT_API void | reduct_function_grow (struct reduct *reduct, reduct_function_t *func) |
| Grow the instruction buffer. | |
| static void | reduct_function_emit (struct reduct *reduct, reduct_function_t *func, reduct_inst_t inst, reduct_uint32_t position) |
| Emit an instruction to the function. | |
| REDUCT_API reduct_const_t | reduct_function_lookup_constant (struct reduct *reduct, reduct_function_t *func, reduct_const_slot_t *slot) |
| Get the index of a constant in a function's constant template, adding it if it doesn't exist. | |
Compiled function.
Definition in file function.h.