Parcourir la source

Merge pull request #92 from legoktm/patch-2

Another thing missed in #91
tags/v0.4
Ben Kurtovic il y a 10 ans
Parent
révision
69ef246433
1 fichiers modifiés avec 4 ajouts et 4 suppressions
  1. +4
    -4
      README.rst

+ 4
- 4
README.rst Voir le fichier

@@ -103,16 +103,16 @@ whitespace::
>>> print(code.filter_templates())
['{{cleanup|date=July 2012}}', '{{bar-stub}}']

You can then convert ``code`` back into a regular ``unicode`` object (for
saving the page!) by calling ``unicode()`` on it::
You can then convert ``code`` back into a regular ``str`` object (for
saving the page!) by calling ``str()`` on it::

>>> text = unicode(code)
>>> text = str(code)
>>> print(text)
{{cleanup|date=July 2012}} '''Foo''' is a [[bar]]. {{bar-stub}}
>>> text == code
True

Likewise, use ``str(code)`` in Python 3.
Likewise, use ``unicode(code)`` in Python 2.

Integration
-----------


Chargement…
Annuler
Enregistrer