From 3c5faa6e594cd7de151c6a3bbd8b1407e69c0c51 Mon Sep 17 00:00:00 2001 From: Luke Shingles Date: Sun, 1 Sep 2024 17:04:32 +0100 Subject: [PATCH] Update vectors.h --- vectors.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/vectors.h b/vectors.h index af0f557ec..d064c52f3 100644 --- a/vectors.h +++ b/vectors.h @@ -45,8 +45,7 @@ template return std::array{x[0] / t, x[1] / t, x[2] / t}; } -[[nodiscard]] [[gnu::const]] constexpr auto cross_prod(const std::array vec_a, - const std::array vec_b) { +[[nodiscard]] constexpr auto cross_prod(const std::array &vec_a, const std::array &vec_b) { return std::array{(vec_a[1] * vec_b[2]) - (vec_b[1] * vec_a[2]), (vec_a[2] * vec_b[0]) - (vec_b[2] * vec_a[0]), (vec_a[0] * vec_b[1]) - (vec_b[0] * vec_a[1])};