Fix markup
This commit is contained in:
parent
043d7cfaaa
commit
685514f87a
|
@ -268,6 +268,7 @@ Order preserving classes
|
|||
------------------------
|
||||
|
||||
::
|
||||
|
||||
class OrderedClass(namespace=collections.OrderedDict()):
|
||||
a = 1
|
||||
b = 2
|
||||
|
@ -278,6 +279,7 @@ Prepopulated namespaces
|
|||
-----------------------
|
||||
|
||||
::
|
||||
|
||||
seed_data = dict(a=1, b=2, c=3)
|
||||
class PrepopulatedClass(namespace=seed_data.copy()):
|
||||
pass
|
||||
|
@ -287,6 +289,7 @@ Cloning a prototype class
|
|||
-------------------------
|
||||
|
||||
::
|
||||
|
||||
class NewClass(namespace=Prototype.__dict__.copy()):
|
||||
pass
|
||||
|
||||
|
@ -295,6 +298,7 @@ Defining an extensible class
|
|||
----------------------------
|
||||
|
||||
::
|
||||
|
||||
class Extensible:
|
||||
namespace = locals()
|
||||
|
||||
|
|
Loading…
Reference in New Issue