]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Fix copyright date: the core of this code actually dates back to 1999
authorGreg Ward <gward@python.net>
Sun, 13 Oct 2002 19:23:18 +0000 (19:23 +0000)
committerGreg Ward <gward@python.net>
Sun, 13 Oct 2002 19:23:18 +0000 (19:23 +0000)
(rev. 1.4 of distutils/fancy_getopt.py).

Lib/textwrap.py

index ff5f7efaa9b95a8b5b5f0d3d061a55acff917c7c..1ea815a34d7472beb61f37e7aa3d8e6599c24293 100644 (file)
@@ -1,7 +1,7 @@
 """Text wrapping and filling.
 """
 
-# Copyright (C) 2001 Gregory P. Ward.
+# Copyright (C) 1999-2001 Gregory P. Ward.
 # Copyright (C) 2002 Python Software Foundation.
 # Written by Greg Ward <gward@python.net>
 
@@ -56,7 +56,7 @@ class TextWrapper:
     # (after stripping out empty strings).
     wordsep_re = re.compile(r'(\s+|'                  # any whitespace
                             r'-*\w{2,}-(?=\w{2,})|'   # hyphenated words
-                            r'(?<=\S)-{2,}(?=\S))')   # em-dash
+                            r'(?<=\S)-{2,}(?=\w))')   # em-dash
 
     # XXX will there be a locale-or-charset-aware version of
     # string.lowercase in 2.3?