Normalize location to a 4-tuple format. Args: location: tuple (lineno, end_lineno, col_offset, end_col_offset) or None Returns: tuple: (lineno, end_lineno, col_offset, end_col_offset)
(location)
| 17 | |
| 18 | |
| 19 | def normalize_location(location): |
| 20 | """Normalize location to a 4-tuple format. |
| 21 | |
| 22 | Args: |
| 23 | location: tuple (lineno, end_lineno, col_offset, end_col_offset) or None |
| 24 | |
| 25 | Returns: |
| 26 | tuple: (lineno, end_lineno, col_offset, end_col_offset) |
| 27 | """ |
| 28 | if location is None: |
| 29 | return DEFAULT_LOCATION |
| 30 | return location |
| 31 | |
| 32 | |
| 33 | def extract_lineno(location): |
no outgoing calls
searching dependent graphs…