From 7bc67b95161a34f8eca635d4000d9602508a9243 Mon Sep 17 00:00:00 2001 From: Tom Harley Date: Mon, 23 Dec 2019 01:32:39 +0000 Subject: checkpoint --- sexpr.h | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 sexpr.h (limited to 'sexpr.h') diff --git a/sexpr.h b/sexpr.h new file mode 100644 index 0000000..6719c3e --- /dev/null +++ b/sexpr.h @@ -0,0 +1,29 @@ +#ifndef SEXPR_H +#define SEXPR_H + +typedef struct YYLTYPE { + int first_line; + int first_column; + int last_line; + int last_column; +} YYLTYPE; +typedef YYLTYPE lloc_t; + +#define YYLTYPE_IS_DECLARED 1 +#define YYLTYPE_IS_TRIVIAL 1 + +typedef struct sexpr { + int type; + union contents { + double f; + char *s; + int i; + struct node { + struct sexpr *l; + struct sexpr *r; + } n; + } contents; + lloc_t lloc; +} sexpr; + +#endif /* SEXPR_H */ -- cgit v1.2.1