pgvector.git / summary / log / commit / refs
commit 034713c803dcb2d77e968de64a5d07a4c44cb557
Author: Andrew Kane <andrew@ankane.org>
Date: Wed Apr 24 04:13:00 2024 +0000
Improved consistency with vector [skip ci]
src/sparsevec.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/sparsevec.c b/src/sparsevec.c
index b6b5a6bd..1c4fc7b0 100644
--- a/src/sparsevec.c
+++ b/src/sparsevec.c
@@ -788,7 +788,7 @@ sparsevec_inner_product(PG_FUNCTION_ARGS)
CheckDims(a, b);
- PG_RETURN_FLOAT8(SparsevecInnerProduct(a, b));
+ PG_RETURN_FLOAT8((double) SparsevecInnerProduct(a, b));
}
/*
@@ -803,7 +803,7 @@ sparsevec_negative_inner_product(PG_FUNCTION_ARGS)
CheckDims(a, b);
- PG_RETURN_FLOAT8(-SparsevecInnerProduct(a, b));
+ PG_RETURN_FLOAT8((double) -SparsevecInnerProduct(a, b));
}
/*
[parent: ed2e460f002f]