(source)
| 684 | # Replace any occurrences of '\r\n?' in the input string with '\n'. |
| 685 | # This converts DOS and Mac line endings to Unix line endings. |
| 686 | def _normalize_line_endings(source): |
| 687 | source = source.replace(b'\r\n', b'\n') |
| 688 | source = source.replace(b'\r', b'\n') |
| 689 | return source |
| 690 | |
| 691 | # Given a string buffer containing Python source code, compile it |
| 692 | # and return a code object. |
no test coverage detected