summaryrefslogtreecommitdiffhomepage
path: root/lexer.h
diff options
context:
space:
mode:
authorJo-Philipp Wich <jo@mein.io>2021-04-27 12:43:38 +0200
committerGitHub <noreply@github.com>2021-04-27 12:43:38 +0200
commit8469c4b1be228f42c46f08852f028f7801b93cc9 (patch)
treef61121e8f89e39787a960e621fc8492e57fc4bc0 /lexer.h
parentf360350bd874aeec0806c8df02c7a20a54c44406 (diff)
parent64eec7f90e945696572ee076b75d1f35e8f2248a (diff)
Merge pull request #5 from jow-/new-type-system
New type system
Diffstat (limited to 'lexer.h')
-rw-r--r--lexer.h11
1 files changed, 3 insertions, 8 deletions
diff --git a/lexer.h b/lexer.h
index 820a986..069e9e0 100644
--- a/lexer.h
+++ b/lexer.h
@@ -18,6 +18,7 @@
#define __LEXER_H_
#include "source.h"
+#include "types.h"
typedef enum {
@@ -121,17 +122,11 @@ typedef enum {
typedef struct {
uc_tokentype_t type;
- json_object *val;
+ uc_value_t *uv;
size_t pos;
} uc_token;
typedef struct {
- bool lstrip_blocks;
- bool trim_blocks;
- bool strict_declarations;
-} uc_parse_config;
-
-typedef struct {
uc_lex_state_t state;
uc_parse_config *config;
uc_source *source;
@@ -170,6 +165,6 @@ uc_token *uc_lexer_next_token(uc_lexer *lex, bool no_regexp);
bool utf8enc(char **out, int *rem, int code);
const char *
-uc_get_tokenname(int type);
+uc_get_tokenname(unsigned type);
#endif /* __LEXER_H_ */