diff --git a/cmd/tools/vfmt.v b/cmd/tools/vfmt.v index 362ca967809c96..fe4706a484408f 100644 --- a/cmd/tools/vfmt.v +++ b/cmd/tools/vfmt.v @@ -183,7 +183,8 @@ fn (foptions &FormatOptions) vlog(msg string) { fn parse_others_in_same_module(mod_name string, file string, mut table ast.Table, prefs &pref.Preferences) { if mod_name != 'main' && prefs.should_compile_c(file) && !file.ends_with('.c.v') - && !file.starts_with('.#') && !file.contains('_d_') && !file.contains('_notd_') { + && !file.ends_with('_windows.v') && !file.starts_with('.#') && !file.contains('_d_') + && !file.contains('_notd_') { // other files in the same module also need to be parsed cur_file_dir := os.dir(file) mut files := os.ls(cur_file_dir) or { panic(err) } diff --git a/vlib/os/filepath_windows.v b/vlib/os/filepath_windows.v index 75c9723c7e402e..776c8f3bcbdfff 100644 --- a/vlib/os/filepath_windows.v +++ b/vlib/os/filepath_windows.v @@ -11,7 +11,7 @@ module os pub fn windows_volume(path string) string { volume_len := win_volume_len(path) if volume_len == 0 { - return os.empty_str + return empty_str } return path[..volume_len] } diff --git a/vlib/v/fmt/fmt_keep_test.v b/vlib/v/fmt/fmt_keep_test.v index 53dcdd30786ac9..1d9fa5e5aba0a8 100644 --- a/vlib/v/fmt/fmt_keep_test.v +++ b/vlib/v/fmt/fmt_keep_test.v @@ -61,7 +61,8 @@ fn run_fmt(mut input_files []string) { fn parse_others_in_same_module(mod_name string, file string, mut table ast.Table, prefs &pref.Preferences) { if mod_name != 'main' && prefs.should_compile_c(file) && !file.ends_with('.c.v') - && !file.starts_with('.#') && !file.contains('_d_') && !file.contains('_notd_') { + && !file.ends_with('_windows.v') && !file.starts_with('.#') && !file.contains('_d_') + && !file.contains('_notd_') { // other files in the same module also need to be parsed cur_file_dir := os.dir(file) mut files := os.ls(cur_file_dir) or { panic(err) }