stage1 使用切片表达字符串而非C字符串 提供属性系统
This commit is contained in:
1 parent
a64a96f9a4
commit
72ae6d6994
14 files changed
+685
-1256
No files matched your search
@@ -6,6 +6,8 @@
|
||||
#include "spl_lexer.h"
|
||||
#include "spl_tok.h"
|
||||
|
||||
#include "spl_attr.h"
|
||||
|
||||
/* clang-format off */
|
||||
#define SPL_AST_KIND_TABLE \
|
||||
X(SPL_AST_NONE, V0, none) \
|
||||
@@ -154,6 +156,7 @@ struct spl_ast_node {
|
||||
usize resolved_def_id;
|
||||
usize resolved_lang_tid;
|
||||
usize expected_lang_tid;
|
||||
spl_attr_id_vec_t attrs;
|
||||
|
||||
union {
|
||||
/* SPL_AST_ROOT */
|
||||
@@ -299,6 +302,7 @@ struct spl_ast_node {
|
||||
} char_lit;
|
||||
struct {
|
||||
const char *data;
|
||||
usize len;
|
||||
} string_lit;
|
||||
struct {
|
||||
bool val;
|
||||
|
||||
Reference in new issue
Block a user