diff --git a/vlib/v/builder/builder.v b/vlib/v/builder/builder.v index bc710646af..fbc2fdc296 100644 --- a/vlib/v/builder/builder.v +++ b/vlib/v/builder/builder.v @@ -439,7 +439,10 @@ fn (mut b Builder) print_warnings_and_errors() { } b.show_total_warns_and_errors_stats() - exit(1) + if b.nr_errors > 0 { + exit(1) + } + exit(0) } if b.pref.is_verbose && b.checker.nr_warnings > 1 {