JVM
operandstack.h
Go to the documentation of this file.
1 #ifndef OPERAND_STACK
2 #define OPERAND_STACK
3 
4 typedef struct OperandStack OperandStack;
5 
6 #include <stdint.h>
7 
8 typedef enum OperandType {
11 } OperandType;
12 
14 {
15  int32_t value;
18 };
19 
20 uint8_t pushOperand(OperandStack** os, int32_t value, OperandType type);
21 uint8_t popOperand(OperandStack** os, int32_t* outPtr, OperandType* outType);
23 
24 #endif // OPERAND_STACK
OperandType
Definition: operandstack.h:8
uint8_t popOperand(OperandStack **os, int32_t *outPtr, OperandType *outType)
Pop the operand out of the top of OperandStack passed as parameter by reference.
Definition: operandstack.c:32
int32_t value
Definition: operandstack.h:15
Definition: operandstack.h:10
Definition: operandstack.h:10
Definition: operandstack.h:9
void freeOperandStack(OperandStack **os)
Free all the elements of the OperandStack passed as parameter by reference.
Definition: operandstack.c:54
Definition: operandstack.h:10
OperandType type
Definition: operandstack.h:16
Definition: operandstack.h:9
uint8_t pushOperand(OperandStack **os, int32_t value, OperandType type)
Push the operand on the top of OperandStack passed as parameter by reference.
Definition: operandstack.c:11
Definition: operandstack.h:9
OperandStack * next
Definition: operandstack.h:17
Definition: operandstack.h:9
Definition: operandstack.h:13