lot of progress on computer
This commit is contained in:
@@ -72,7 +72,7 @@ typedef struct nn_architecture {
|
||||
char *(*serialize)(nn_computer *computer, void *state, void *userdata);
|
||||
void (*deserialize)(nn_computer *computer, const char *data, void *state, void *userdata);
|
||||
} nn_architecture;
|
||||
typedef const char *nn_address;
|
||||
typedef char *nn_address;
|
||||
|
||||
// Values for architectures
|
||||
|
||||
@@ -223,6 +223,7 @@ void nn_setCError(nn_computer *computer, const char *err);
|
||||
|
||||
nn_component *nn_newComponent(nn_computer *computer, nn_address address, int slot, nn_componentTable *table, void *userdata);
|
||||
void nn_removeComponent(nn_computer *computer, nn_address address);
|
||||
void nn_destroyComponent(nn_component *component);
|
||||
nn_computer *nn_getComputerOfComponent(nn_component *component);
|
||||
nn_address nn_getComponentAddress(nn_component *component);
|
||||
int nn_getComponentSlot(nn_component *component);
|
||||
@@ -244,7 +245,8 @@ const char *nn_methodDoc(nn_componentTable *table, const char *methodName);
|
||||
|
||||
// Component calling
|
||||
|
||||
void nn_invokeComponentMethod(nn_component *component, const char *name);
|
||||
/* Returns false if the method does not exist */
|
||||
bool nn_invokeComponentMethod(nn_component *component, const char *name);
|
||||
void nn_resetCall(nn_computer *computer);
|
||||
void nn_addArgument(nn_computer *computer, nn_value arg);
|
||||
void nn_return(nn_computer *computer, nn_value val);
|
||||
|
||||
Reference in New Issue
Block a user