(doc)
| 4 | |
| 5 | |
| 6 | def short_doc(doc): |
| 7 | if not doc: |
| 8 | return '' |
| 9 | short = doc |
| 10 | if '.' in doc and 10 < doc.index('.') < 100: |
| 11 | short = doc.split('.')[0] + '.' |
| 12 | elif '\n' in doc and doc.index('\n') < 100: |
| 13 | short = doc.split('\n')[0] |
| 14 | elif len(doc) > 140: |
| 15 | short = doc[:97] + '...' |
| 16 | |
| 17 | lines = doc.split('\n') |
| 18 | if '->' in short and len(lines) > 2: |
| 19 | remainder = '\n'.join(lines[1:]) |
| 20 | return short_doc(remainder.strip()) |
| 21 | |
| 22 | return short |
| 23 | |
| 24 | def get_method_params(thing): |
| 25 | params = [] |
no outgoing calls
no test coverage detected