mirror of
https://github.com/Ed94/Odin.git
synced 2026-08-06 15:48:51 +00:00
Suggest -all-packages if testing empty directory
This commit is contained in:
@@ -5508,11 +5508,15 @@ gb_internal AstPackage *try_add_import_path(Parser *p, String path, String const
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (files_with_ext == 0 || files_to_reserve == 1) {
|
if (files_with_ext == 0 || files_to_reserve == 1) {
|
||||||
|
ERROR_BLOCK();
|
||||||
if (files_with_ext != 0) {
|
if (files_with_ext != 0) {
|
||||||
syntax_error(pos, "Directory contains no .odin files for the specified platform: %.*s", LIT(rel_path));
|
syntax_error(pos, "Directory contains no .odin files for the specified platform: %.*s", LIT(rel_path));
|
||||||
} else {
|
} else {
|
||||||
syntax_error(pos, "Empty directory that contains no .odin files: %.*s", LIT(rel_path));
|
syntax_error(pos, "Empty directory that contains no .odin files: %.*s", LIT(rel_path));
|
||||||
}
|
}
|
||||||
|
if (build_context.command_kind == Command_test) {
|
||||||
|
error_line("\tSuggestion: Make an .odin file that imports packages to test and use the `-all-packages` flag.");
|
||||||
|
}
|
||||||
return nullptr;
|
return nullptr;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user