From 324efa3d3106f8cec47b5cc5bf7b1871a5a659ba Mon Sep 17 00:00:00 2001 From: Guido van Rossum Date: Wed, 18 May 2005 03:58:29 +0000 Subject: [PATCH] Outdent "return +s" and explain why. Thanks Raymond! --- pep-0343.txt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pep-0343.txt b/pep-0343.txt index 57b58d026..2e9884712 100644 --- a/pep-0343.txt +++ b/pep-0343.txt @@ -414,7 +414,9 @@ Examples num *= x * x sign *= -1 s += num / fact * sign - return +s + # The "+s" rounds back to the original precision, + # so this must be outside the do-statement: + return +s An alternative version of the generator saves the entire context instead of just the precision attribute. This is more