From 70d129fcd71ce6295026fae24db6cc89936fd5e9 Mon Sep 17 00:00:00 2001 From: Rangi42 Date: Tue, 5 Aug 2025 11:26:21 -0400 Subject: [PATCH] Color "warning:" yellow in `warnx` --- src/diagnostics.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/diagnostics.cpp b/src/diagnostics.cpp index f207a969..5b15e8f3 100644 --- a/src/diagnostics.cpp +++ b/src/diagnostics.cpp @@ -2,9 +2,13 @@ #include "diagnostics.hpp" +#include "style.hpp" + void warnx(char const *fmt, ...) { va_list ap; + style_Set(stderr, STYLE_YELLOW, true); fputs("warning: ", stderr); + style_Reset(stderr); va_start(ap, fmt); vfprintf(stderr, fmt, ap); va_end(ap);