add declaring and assignment with parser LHS support
This commit is contained in:
16
src/parser/declaration/declaration.h
Normal file
16
src/parser/declaration/declaration.h
Normal file
@@ -0,0 +1,16 @@
|
||||
#ifndef DECLARATION_H
|
||||
#define DECLARATION_H
|
||||
#include "../parser.h"
|
||||
#include "../../lexer/token.h" // for Token
|
||||
|
||||
typedef struct {
|
||||
char * name;
|
||||
bool is_function;
|
||||
DArray args; // string[]
|
||||
ParsedValue * from;
|
||||
} ParsedDeclaration;
|
||||
|
||||
// Function declaration for parsing an identifier
|
||||
ParsedValue *parse_declaration(char *file, DArray *parsed, DArray *tokens, size_t *index);
|
||||
|
||||
#endif // DECLARATION_H
|
||||
Reference in New Issue
Block a user