-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathparser_types.h
More file actions
47 lines (38 loc) · 847 Bytes
/
Copy pathparser_types.h
File metadata and controls
47 lines (38 loc) · 847 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
#ifndef PARSER_TYPES_H
#define PARSER_TYPES_H
#include "ast.h"
// 定义参数列表结构 - 现在在 ast.h 中定义
// typedef struct {
// char** parameters;
// int parameter_count;
// } ParamList;
// 其他结构体定义保持不变
typedef struct {
ASTNode** arguments;
int argument_count;
} ArgList;
// 添加类相关的结构体
typedef struct {
ASTNode** elements;
int element_count;
} ClassElementList;
typedef struct {
char* kind;
char* key;
ASTNode* value;
} MethodDefinition;
typedef struct {
char* key;
ASTNode* value;
} PropertyDefinition;
// 添加数组相关的结构体
typedef struct {
ASTNode** elements;
int element_count;
} ArrayElementList;
// 添加属性列表结构体
typedef struct {
ASTNode** properties;
int property_count;
} PropertyList;
#endif