@@ -853,10 +853,9 @@ def __init__(self, linejunk=None, charjunk=None):
853853 and return true iff the string is junk. The module-level function
854854 `IS_LINE_JUNK` may be used to filter out lines without visible
855855 characters, except for at most one splat ('#'). It is recommended
856- to leave linejunk None; as of Python 2.3, the underlying
857- SequenceMatcher class has grown an adaptive notion of "noise" lines
858- that's better than any static definition the author has ever been
859- able to craft.
856+ to leave linejunk None; the underlying SequenceMatcher class has
857+ an adaptive notion of "noise" lines that's better than any static
858+ definition the author has ever been able to craft.
860859
861860 - `charjunk`: A function that should accept a string of length 1. The
862861 module-level function `IS_CHARACTER_JUNK` may be used to filter out
@@ -1299,17 +1298,18 @@ def ndiff(a, b, linejunk=None, charjunk=IS_CHARACTER_JUNK):
12991298 Compare `a` and `b` (lists of strings); return a `Differ`-style delta.
13001299
13011300 Optional keyword parameters `linejunk` and `charjunk` are for filter
1302- functions ( or None) :
1301+ functions, or can be None:
13031302
1304- - linejunk: A function that should accept a single string argument, and
1303+ - linejunk: A function that should accept a single string argument and
13051304 return true iff the string is junk. The default is None, and is
1306- recommended; as of Python 2.3, an adaptive notion of "noise" lines is
1307- used that does a good job on its own .
1305+ recommended; the underlying SequenceMatcher class has an adaptive
1306+ notion of "noise" lines .
13081307
1309- - charjunk: A function that should accept a string of length 1. The
1310- default is module-level function IS_CHARACTER_JUNK, which filters out
1311- whitespace characters (a blank or tab; note: bad idea to include newline
1312- in this!).
1308+ - charjunk: A function that accepts a character (string of length
1309+ 1), and returns true iff the character is junk. The default is
1310+ the module-level function IS_CHARACTER_JUNK, which filters out
1311+ whitespace characters (a blank or tab; note: it's a bad idea to
1312+ include newline in this!).
13131313
13141314 Tools/scripts/ndiff.py is a command-line front-end to this function.
13151315
@@ -1680,7 +1680,7 @@ def __init__(self,tabsize=8,wrapcolumn=None,linejunk=None,
16801680 tabsize -- tab stop spacing, defaults to 8.
16811681 wrapcolumn -- column number where lines are broken and wrapped,
16821682 defaults to None where lines are not wrapped.
1683- linejunk,charjunk -- keyword arguments passed into ndiff() (used to by
1683+ linejunk,charjunk -- keyword arguments passed into ndiff() (used by
16841684 HtmlDiff() to generate the side by side HTML differences). See
16851685 ndiff() documentation for argument default values and descriptions.
16861686 """
0 commit comments