From cf3fb259329eedfa9d2c802b2ea5ced287c21e78 Mon Sep 17 00:00:00 2001 From: Georg Brandl Date: Sun, 21 Oct 2007 10:52:38 +0000 Subject: Add :term: for generators. --- Doc/library/difflib.rst | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'Doc/library/difflib.rst') diff --git a/Doc/library/difflib.rst b/Doc/library/difflib.rst index 60367a40d5..4da3be938d 100644 --- a/Doc/library/difflib.rst +++ b/Doc/library/difflib.rst @@ -126,8 +126,8 @@ diffs. For comparing directories and files, see also, the :mod:`filecmp` module. .. function:: context_diff(a, b[, fromfile][, tofile][, fromfiledate][, tofiledate][, n][, lineterm]) - Compare *a* and *b* (lists of strings); return a delta (a generator generating - the delta lines) in context diff format. + Compare *a* and *b* (lists of strings); return a delta (a :term:`generator` + generating the delta lines) in context diff format. Context diffs are a compact way of showing just the lines that have changed plus a few lines of context. The changes are shown in a before/after style. The @@ -181,8 +181,8 @@ diffs. For comparing directories and files, see also, the :mod:`filecmp` module. .. function:: ndiff(a, b[, linejunk][, charjunk]) - Compare *a* and *b* (lists of strings); return a :class:`Differ`\ -style delta - (a generator generating the delta lines). + Compare *a* and *b* (lists of strings); return a :class:`Differ`\ -style + delta (a :term:`generator` generating the delta lines). Optional keyword parameters *linejunk* and *charjunk* are for filter functions (or ``None``): @@ -242,8 +242,8 @@ diffs. For comparing directories and files, see also, the :mod:`filecmp` module. .. function:: unified_diff(a, b[, fromfile][, tofile][, fromfiledate][, tofiledate][, n][, lineterm]) - Compare *a* and *b* (lists of strings); return a delta (a generator generating - the delta lines) in unified diff format. + Compare *a* and *b* (lists of strings); return a delta (a :term:`generator` + generating the delta lines) in unified diff format. Unified diffs are a compact way of showing just the lines that have changed plus a few lines of context. The changes are shown in a inline style (instead of @@ -442,7 +442,7 @@ use :meth:`set_seq2` to set the commonly used sequence once and call .. method:: SequenceMatcher.get_grouped_opcodes([n]) - Return a generator of groups with up to *n* lines of context. + Return a :term:`generator` of groups with up to *n* lines of context. Starting with the groups returned by :meth:`get_opcodes`, this method splits out smaller change clusters and eliminates intervening ranges which have no changes. -- cgit v1.2.1