diff --git a/vlib/v/builder/builder.v b/vlib/v/builder/builder.v index 6ba346eef5..d4bbccba6c 100644 --- a/vlib/v/builder/builder.v +++ b/vlib/v/builder/builder.v @@ -33,11 +33,10 @@ pub fn new_builder(pref &pref.Preferences) Builder { compiled_dir := if os.is_dir(rdir) { rdir } else { os.dir(rdir) } table := table.new_table() if pref.use_color == .always { - // TODO - //util.emanager.set_support_color(true) + util.emanager.set_support_color(true) } if pref.use_color == .never { - //util.emanager.set_support_color(false) + util.emanager.set_support_color(false) } msvc := find_msvc() or { if pref.ccompiler == 'msvc' { diff --git a/vlib/v/util/errors.v b/vlib/v/util/errors.v index 660fb18180..ed65b382cb 100644 --- a/vlib/v/util/errors.v +++ b/vlib/v/util/errors.v @@ -39,8 +39,11 @@ pub fn new_error_manager() &EManager { } } -pub fn (mut e EManager) set_support_color(b bool) { - e.support_color = b +pub fn (e &EManager) set_support_color(b bool) { + unsafe { + mut me := e + me.support_color = b + } } fn bold(msg string) string {