I am new to Julia with mostly C and some MATLAB background. Julia seems to
provide an easy way to write C like code with MATLAB ease! To get started,
I am trying understand C interface. Is it be possible to create a Julia
type for the following struct?
typedef struct itree {
bool isLeaf;
int n; //number of elements
union {
int *i; //(isLeaf == 1): pointer to int array
struct itree **s; //(isLeaf == 0): pointer to itree array
};
} itree;
It seems, that the size of the pointer should be the same. So, anonymous
union should be possible.
I would appreciate any suggestions.
Thanks,
~Sue