From 81adef19bf63a6daff7f3379e300a74cda64054c Mon Sep 17 00:00:00 2001 From: Cubitect Date: Sun, 14 Aug 2022 17:22:50 +0200 Subject: [PATCH] Avoid nonsensical warning about unary unsigned negation --- biome_tree.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/biome_tree.c b/biome_tree.c index 69bf4c3..d58b4af 100644 --- a/biome_tree.c +++ b/biome_tree.c @@ -4346,8 +4346,8 @@ uint64_t get_np_dist(const struct _args *arg, int idx) { uint8_t idx = (node >> 8*i) & 0xFF; uint64_t a, b, d; - a = +arg->np[i] - arg->param[idx][1]; - b = -arg->np[i] + arg->param[idx][0]; + a = arg->np[i] - arg->param[idx][1]; + b = arg->param[idx][0] - arg->np[i]; d = (int64_t)a > 0 ? a : (int64_t)b > 0 ? b : 0; d = d * d; ds += d;