From: Raymond Hettinger Date: Fri, 28 Mar 2014 23:39:25 +0000 (-0700) Subject: Issue 21014: Use booleans instead of 0 and 1 in examples. X-Git-Tag: v3.4.1rc1~166 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=4ab532bbfeb6dd6c9804996e19b665b22de65d56;p=python Issue 21014: Use booleans instead of 0 and 1 in examples. --- diff --git a/Doc/howto/logging-cookbook.rst b/Doc/howto/logging-cookbook.rst index 833ad15d04..82c8f51382 100644 --- a/Doc/howto/logging-cookbook.rst +++ b/Doc/howto/logging-cookbook.rst @@ -416,7 +416,7 @@ module. Here is a basic working example:: Simple TCP socket-based logging receiver suitable for testing. """ - allow_reuse_address = 1 + allow_reuse_address = True def __init__(self, host='localhost', port=logging.handlers.DEFAULT_TCP_LOGGING_PORT, diff --git a/Doc/tutorial/interpreter.rst b/Doc/tutorial/interpreter.rst index 9ab77f8009..8e8395a349 100644 --- a/Doc/tutorial/interpreter.rst +++ b/Doc/tutorial/interpreter.rst @@ -106,7 +106,7 @@ before printing the first prompt:: Continuation lines are needed when entering a multi-line construct. As an example, take a look at this :keyword:`if` statement:: - >>> the_world_is_flat = 1 + >>> the_world_is_flat = True >>> if the_world_is_flat: ... print("Be careful not to fall off!") ...