diff --git a/core/math/math.odin b/core/math/math.odin index caaa6f51b..b81598da9 100644 --- a/core/math/math.odin +++ b/core/math/math.odin @@ -1196,6 +1196,7 @@ sum :: proc "contextless" (x: $T/[]$E) -> (res: E) prod :: proc "contextless" (x: $T/[]$E) -> (res: E) where intrinsics.type_is_numeric(E) { + res = 1 for i in x { res *= i }