From 2350056bf5c550f15a1a9fe072d326d4dd7a4478 Mon Sep 17 00:00:00 2001 From: Nick Coghlan Date: Thu, 27 Mar 2014 21:22:38 +1000 Subject: [PATCH] PEP 461: markup tweaks --- pep-0461.txt | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/pep-0461.txt b/pep-0461.txt index 4b43cc655..aa0755957 100644 --- a/pep-0461.txt +++ b/pep-0461.txt @@ -64,7 +64,7 @@ code `%x`:: b"%x" % val -is equivalent to +is equivalent to:: ("%x" % val).encode("ascii") @@ -92,7 +92,7 @@ Examples:: ``%s`` is included for two reasons: 1) `b` is already a format code for ``format`` numerics (binary), and 2) it will make 2/3 code easier as Python 2.x -code uses ``%s``; however, it is restricted in what it will accept:: +code uses ``%s``; however, it is restricted in what it will accept: - input type supports ``Py_buffer`` [6]_? use it to collect the necessary bytes @@ -128,7 +128,7 @@ value. Use cases include developing a new protocol and writing landmarks into the stream; debugging data going into an existing protocol to see if the problem is the protocol itself or bad data; a fall-back for a serialization format; or any situation where defining ``__bytes__`` would not be appropriate -but a readable/informative representation is needed [8]. +but a readable/informative representation is needed [8]_. Examples:: @@ -178,8 +178,8 @@ Various new special methods were proposed, such as ``__ascii__``, ``__format_bytes__``, etc.; such methods are not needed at this time, but can be visited again later if real-world use shows deficiencies with this solution. -A competing PEP, ``PEP 460 Add binary interpolation and formatting`` [9], also -exists. +A competing PEP, ``PEP 460 Add binary interpolation and formatting`` [9]_, +also exists. Objections