(self, suffix, /)
| 1509 | return self.__class__(self.data.removeprefix(prefix)) |
| 1510 | |
| 1511 | def removesuffix(self, suffix, /): |
| 1512 | if isinstance(suffix, UserString): |
| 1513 | suffix = suffix.data |
| 1514 | return self.__class__(self.data.removesuffix(suffix)) |
| 1515 | |
| 1516 | def encode(self, encoding='utf-8', errors='strict'): |
| 1517 | encoding = 'utf-8' if encoding is None else encoding |
no test coverage detected