Commits

Mikhail Korobov committed d2cacc7

Remove some of unneeded colons in docstrings (this fixes sphinx warnings).

  • Participants
  • Parent commits 1cf6d0d

Comments (0)

Files changed (2)

File pymorphy2/shapes.py

 def is_latin(token):
     """
     Return True if all token letters are latin and there is at
-    least one latin letter in the token::
+    least one latin letter in the token:
 
         >>> is_latin('foo')
         True
 def is_punctuation(token):
     """
     Return True if a word contains only spaces and punctuation marks
-    and there is at least one punctuation mark::
+    and there is at least one punctuation mark:
 
         >>> is_punctuation(', ')
         True
         False
 
     """
-    if isinstance(token, bytes): # python 2.x ascii str
+    if isinstance(token, bytes):  # python 2.x ascii str
         token = token.decode('ascii')
 
     return (
 
 def is_roman_number(token):
     """
-    Return True if token looks like a Roman number::
+    Return True if token looks like a Roman number:
 
         >>> is_roman_number('II')
         True
 
 def restore_word_case(word, example):
     """
-    Make the ``word`` be the same case as an ``example``::
+    Make the ``word`` be the same case as an ``example``:
 
         >>> restore_word_case('bye', 'Hello')
         'Bye'
         >>> restore_word_case('123--do', 'anti--IEEE')
         '123--DO'
 
-    In the alignment fails, the reminder is lower-cased::
+    In the alignment fails, the reminder is lower-cased:
 
         >>> restore_word_case('foo-BAR-BAZ', 'Baz-Baz')
         'Foo-Bar-baz'

File pymorphy2/utils.py

 
 def combinations_of_all_lengths(it):
     """
-    Return an iterable with all possible combinations of items from ``it``::
+    Return an iterable with all possible combinations of items from ``it``:
 
         >>> for comb in combinations_of_all_lengths('ABC'):
         ...     print("".join(comb))
 
 def longest_common_substring(data):
     """
-    Return a longest common substring of a list of strings::
+    Return a longest common substring of a list of strings:
 
         >>> longest_common_substring(["apricot", "rice", "cricket"])
         'ric'