#alias type declarations; core library additions; _global import name for the global scope

This commit is contained in:
gingerBill
2017-10-29 11:35:21 +00:00
parent 0ed34af19d
commit a43b89f36e
18 changed files with 367 additions and 49 deletions
+6
View File
@@ -2131,6 +2131,12 @@ bool check_type_internal(Checker *c, AstNode *e, Type **type, Type *named_type)
return check_type_internal(c, ht->type, type, named_type);
case_end;
case_ast_node(at, AliasType, e);
error(e, "Invalid use of `#alias`");
// NOTE(bill): Treat it as a HelperType to remove errors
return check_type_internal(c, at->type, type, named_type);
case_end;
case_ast_node(pt, PolyType, e);
AstNode *ident = pt->type;
if (ident->kind != AstNode_Ident) {