diff --git a/doc/langref.html.in b/doc/langref.html.in
index cf12894ca6..95c1d2eee0 100644
--- a/doc/langref.html.in
+++ b/doc/langref.html.in
@@ -3128,7 +3128,7 @@ test "while null capture" {
while (eventuallyNullSequence()) |value| {
sum2 += value;
} else {
- assert(sum1 == 3);
+ assert(sum2 == 3);
}
}