From c74aea420c662039072f606b2d5ef1c73426e481 Mon Sep 17 00:00:00 2001 From: Nakidai Date: Sat, 24 Aug 2024 14:29:55 +0300 Subject: Add more code Add some funcitons to work with variables, add more instructions and add ability to stop the code from `ccl_instruction` --- include/instructions.h | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 include/instructions.h (limited to 'include/instructions.h') diff --git a/include/instructions.h b/include/instructions.h new file mode 100644 index 0000000..adada87 --- /dev/null +++ b/include/instructions.h @@ -0,0 +1,21 @@ +#ifndef __CCL_INSTRUCTIONS_H__ +#define __CCL_INSTRUCTIONS_H__ + +#include "3cl.h" + + +#define INST(NAME) \ + struct CCLFrame *ccl_instruction_##NAME(struct CCL *ccl, struct CCLFrame *frame) + +INST(nop); +INST(pushzero); +INST(increment); +INST(decrement); +INST(add); +INST(subtract); +INST(reverse); + +#undef INST +#define INST(NAME) ccl_instruction_##NAME + +#endif /* __CCL_INSTRUCTIONS_H__ */ -- cgit 1.4.1