| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
#ifndef LISTS_H |
| 9 |
|
| 10 |
#include "acode.h" |
| 11 |
#include "types.h" |
| 12 |
|
| 13 |
extern void initArray(void *array); |
| 14 |
|
| 15 |
#define isEndOfArray(x) implementationOfIsEndOfList((Aword *) (x)) |
| 16 |
extern bool implementationOfIsEndOfList(Aword *adr); |
| 17 |
|
| 18 |
#define setEndOfArray(x) implementationOfSetEndOfArray((Aword *) (x)) |
| 19 |
extern void implementationOfSetEndOfArray(Aword *adr); |
| 20 |
|
| 21 |
#define lengthOfArray(array) lengthOfArrayImplementation((array), sizeof(*(array))) |
| 22 |
extern int lengthOfArrayImplementation(void *array, int element_size_in_bytes); |
| 23 |
|
| 24 |
#define addElement(array, element) addElementImplementation((array), (&element), sizeof(element)) |
| 25 |
extern void addElementImplementation(void *array_of_any_type, void *element_of_any_size, int element_size_in_bytes); |
| 26 |
#endif |