From 55dddad995aaccbc646dd176850547b1073590e9 Mon Sep 17 00:00:00 2001 From: Andy Dienes <51664769+adienes@users.noreply.github.com> Date: Thu, 3 Jul 2025 12:22:14 -0400 Subject: [PATCH] make `dot` docstring match the implementation --- src/generic.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/generic.jl b/src/generic.jl index c8336f87..174616f5 100644 --- a/src/generic.jl +++ b/src/generic.jl @@ -938,7 +938,7 @@ vector is conjugated. `dot` also works on arbitrary iterable objects, including arrays of any dimension, as long as `dot` is defined on the elements. -`dot` is semantically equivalent to `sum(dot(vx,vy) for (vx,vy) in zip(x, y))`, +`dot` is semantically equivalent to `reduce(+, dot(vx,vy) for (vx,vy) in zip(x, y))`, with the added restriction that the arguments must have equal lengths. `x ⋅ y` (where `⋅` can be typed by tab-completing `\\cdot` in the REPL) is a synonym for