# HG changeset patch
# User David Roe <roed@math.harvard.edu>
# Date 1200511407 18000
# Node ID 811fb2e1982db202565323991e0b51c9ce91e36e
# Parent d6493bcd84a594f460cbfb3cb00594dce1471435
A few changes in how Python classes are handled.
diff -r d6493bcd84a5 -r 811fb2e1982d sage-coverage
a
|
b
|
def functions_without_doctests(file): |
41 | 41 | file = file[j:] |
42 | 42 | continue |
43 | 43 | |
44 | | if i == ii: |
45 | | function_name = ' '.join(file[i:j].lstrip('class').split()) |
46 | | else: |
47 | | function_name = ' '.join(file[i:j].lstrip('def').split()) |
| 44 | function_name = ' '.join(file[i:j].lstrip('def').split()) |
48 | 45 | if function_name.find("(") == -1 and (i != ii and function_name[:5] != 'class'): |
49 | 46 | file = file[i+3:] |
50 | 47 | continue |
51 | 48 | bare_function_name = function_name[:function_name.find("(")].rstrip() |
| 49 | if i == ii: |
| 50 | bare_function_name = ' '.join(bare_function_name.lstrip('class').split()) |
52 | 51 | # a cdef'd or cpdef'd function may or may not indicate the type of its return value |
53 | 52 | # if it does, then function name and bare function name have that return |
54 | 53 | # value type at the beginning. |