Return the next character from ``header`` at the given position. Return :obj:`None` at the end of ``header``. We never need to peek more than one character ahead.
(header: str, pos: int)
| 71 | |
| 72 | |
| 73 | def peek_ahead(header: str, pos: int) -> str | None: |
| 74 | """ |
| 75 | Return the next character from ``header`` at the given position. |
| 76 | |
| 77 | Return :obj:`None` at the end of ``header``. |
| 78 | |
| 79 | We never need to peek more than one character ahead. |
| 80 | |
| 81 | """ |
| 82 | return None if pos == len(header) else header[pos] |
| 83 | |
| 84 | |
| 85 | _OWS_re = re.compile(r"[\t ]*") |
no outgoing calls
no test coverage detected
searching dependent graphs…