radish/slr.h

21 lines
326 B
C
Raw Normal View History

2024-05-16 19:40:44 +02:00
#ifndef SLR_H_
#define SLR_H_
typedef enum {
INT,
KEYWORD,
SEPARATOR,
END_OF_TOKENS,
} TokenType;
typedef struct {
TokenType type;
char *value;
} Token;
2024-05-16 20:03:04 +02:00
void print_token(Token token);
Token *generate_number(char *current, int *current_index);
Token *generate_keyword(char *current, int *current_index);
2024-05-16 19:40:44 +02:00
#endif