We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 2c275f3 + c3de9df commit 39a54d5Copy full SHA for 39a54d5
1 file changed
docs/writing/gotchas.rst
@@ -23,7 +23,7 @@ Python's treatment of mutable default arguments in function definitions.
23
What You Wrote
24
~~~~~~~~~~~~~~
25
26
-.. testcode::
+.. code-block:: python
27
28
def append_to(element, to=[]):
29
to.append(element)
@@ -32,7 +32,7 @@ What You Wrote
32
What You Might Have Expected to Happen
33
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
34
35
36
37
my_list = append_to(12)
38
print my_list
0 commit comments