From 81a2e7a772b7564c6ac7a51cd5115d358fe56044 Mon Sep 17 00:00:00 2001 From: "Eliyaan (Nopana)" <103932369+Eliyaan@users.noreply.github.com> Date: Thu, 13 Feb 2025 20:32:01 +0100 Subject: [PATCH] tools: fix warnings in `v reduce` (#23709) --- cmd/tools/vreduce.v | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/cmd/tools/vreduce.v b/cmd/tools/vreduce.v index b63cec0f91..8aa9c4fcf1 100644 --- a/cmd/tools/vreduce.v +++ b/cmd/tools/vreduce.v @@ -353,5 +353,7 @@ fn show_code_stats(code string, params ShowParams) { } fn warn_on_false(res bool, what string, loc string) { - log.warn('${what} is false, at ${loc}') + if !res { + log.warn('${what} is false, at ${loc}') + } }