#ifndef SYMTAB_H
#define SYMTAB_H
#define PARAM_NUMBER 5
static char *symbol_kinds[] = { "VARIABLE", "METHOD", "CLASS"};
static char *symbol_functions[] = { "DECLARATION", "PARAMETER", "INSTANTIATION","USE","ASSIGNMENT"};
extern int line;
typedef struct node {
char* name;
char* function;
char* kind;
char* type;
int initialized;
int level;
char* params_types[PARAM_NUMBER] ;
char* params_names[PARAM_NUMBER] ;
int params_init[PARAM_NUMBER] ;
int param_index ;
int class_id;
int line;
} NODE;
#define SYMBOL_TABLE_LENGTH 300
NODE symbol_table[SYMBOL_TABLE_LENGTH];
void check_main(void);
int insert_symbol(char *name,char* function,char* kind, char* type,int level,int class_id);
int remove_param(int index);
int get_next_empty_element(void);
int get_last_element_index(void);
int lookup_variable(char* name,char* type,int level, int class_id);
int lookup_class(char* name,int class_id);
int lookup_method(char* name,char* return_type,int class_id);
int lookup_declarations(char *name,char* function, char* kind,int level, int class_id);
void insert_call_param(int index,char* val,char* type);
void set_param(char* name, char* type);
void print_symtab(void);
#endif