From 9c1c52b7779fe073e5f4840f57a1833c23ac6616 Mon Sep 17 00:00:00 2001 From: Ezio Melotti Date: Mon, 24 Sep 2012 17:30:39 +0300 Subject: [PATCH] #16019, #16020: fix syntax highlight. --- Doc/tutorial/stdlib2.rst | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/Doc/tutorial/stdlib2.rst b/Doc/tutorial/stdlib2.rst index 514d583d944..a5ba4725020 100644 --- a/Doc/tutorial/stdlib2.rst +++ b/Doc/tutorial/stdlib2.rst @@ -95,7 +95,7 @@ placeholders unchanged if data is missing:: >>> d = dict(item='unladen swallow') >>> t.substitute(d) Traceback (most recent call last): - . . . + ... KeyError: 'owner' >>> t.safe_substitute(d) 'Return the unladen swallow to $owner.' @@ -218,7 +218,9 @@ At its simplest, log messages are sent to a file or to ``sys.stderr``:: logging.error('Error occurred') logging.critical('Critical error -- shutting down') -This produces the following output:: +This produces the following output: + +.. code-block:: none WARNING:root:Warning:config file server.conf not found ERROR:root:Error occurred @@ -309,6 +311,8 @@ tree searches:: >>> print "Handling", d.popleft() Handling task1 +:: + unsearched = deque([starting_node]) def breadth_first_search(unsearched): node = unsearched.popleft()