Enforce core:builtin and core:intrinsics for imports

This commit is contained in:
gingerBill
2021-08-21 13:44:16 +01:00
parent 32bdad322a
commit f0437a4242
40 changed files with 46 additions and 41 deletions

View File

@@ -5184,7 +5184,12 @@ bool determine_path_from_string(BlockingMutex *file_mutex, Ast *node, String bas
if (is_package_name_reserved(file_str)) {
*path = file_str;
return true;
if (collection_name == "core") {
return true;
} else {
syntax_error(node, "The package '%.*s' must be imported with the core library collection: 'core:%.*s'", LIT(file_str), LIT(file_str));
return false;
}
}
if (file_mutex) mutex_lock(file_mutex);