mirror of
https://github.com/Ed94/Odin.git
synced 2026-07-23 07:57:52 +00:00
Reorganize runtime package
This commit is contained in:
+12
-6
@@ -27,7 +27,7 @@ struct CommentGroup {
|
||||
|
||||
enum PackageKind {
|
||||
Package_Normal,
|
||||
Package_Builtin,
|
||||
Package_Runtime,
|
||||
Package_Init,
|
||||
};
|
||||
|
||||
@@ -85,11 +85,11 @@ struct AstFile {
|
||||
|
||||
|
||||
struct AstPackage {
|
||||
isize id;
|
||||
PackageKind kind;
|
||||
String name;
|
||||
String fullpath;
|
||||
Map<AstFile *> files; // Key: String (names)
|
||||
isize id;
|
||||
PackageKind kind;
|
||||
String name;
|
||||
String fullpath;
|
||||
Array<AstFile *> files;
|
||||
|
||||
Scope * scope; // NOTE(bill): Created in checker
|
||||
DeclInfo *decl_info; // NOTE(bill): Created in checker
|
||||
@@ -356,6 +356,12 @@ AST_NODE_KIND(_DeclBegin, "", struct {}) \
|
||||
bool is_mutable; \
|
||||
bool been_handled; \
|
||||
}) \
|
||||
AST_NODE_KIND(PackageDecl, "package declaration", struct { \
|
||||
Token token; \
|
||||
Token name; \
|
||||
CommentGroup docs; \
|
||||
CommentGroup comment; \
|
||||
}) \
|
||||
AST_NODE_KIND(ImportDecl, "import declaration", struct { \
|
||||
AstPackage *package; \
|
||||
Token token; \
|
||||
|
||||
Reference in New Issue
Block a user