From f298a72ada538646a290a5a0fa9448ff68e315b5 Mon Sep 17 00:00:00 2001 From: Andrew Kane Date: Sun, 13 Oct 2024 19:46:16 -0700 Subject: [PATCH] Added casting [skip ci] --- src/intvec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/intvec.c b/src/intvec.c index 58a57ce..5271829 100644 --- a/src/intvec.c +++ b/src/intvec.c @@ -630,7 +630,7 @@ intvec_l2_norm(PG_FUNCTION_ARGS) /* Auto-vectorized */ for (int i = 0; i < a->dim; i++) - norm += ax[i] * ax[i]; + norm += (int) ax[i] * (int) ax[i]; PG_RETURN_FLOAT8(sqrt((double) norm)); }