Oxygen Basic

Programming => Problems & Solutions => Topic started by: Aurel on December 29, 2013, 12:41:20 AM

Title: TypeDef structure
Post by: Aurel on December 29, 2013, 12:41:20 AM
how translate this to oxygen...

Code: [Select]
/* -------- symbol table ------------ */
typedef struct {
    char *symbol;   /* points to symbol name                 */
    char *location; /* points to function code (NULL if int) */
    char **tblloc;  /* points to table array (NULL if func)  */
    int ival;       /* value of integer                      */
} SYMBOL;
Title: Re: TypeDef structure
Post by: Aurel on December 29, 2013, 05:05:15 AM
it looks that this work... ;D

Code: [Select]
/* ------- intrinsic function table -------- */
typedef struct INTRINSIC
{
    char *fname;
    int (*fn)(int *);
} ;

typedef struct SYMBOL
{
    char *symbol;   /* points to symbol name                 */
    char *location; /* points to function code (NULL if int) */
    char **tblloc;  /* points to table array (NULL if func)  */
    int ival;       /* value of integer                      */
};

I have in plan to translate SI to Oxygen... 8)