(self, value)
| 1433 | dispatch[BINFLOAT[0]] = load_binfloat |
| 1434 | |
| 1435 | def _decode_string(self, value): |
| 1436 | # Used to allow strings from Python 2 to be decoded either as |
| 1437 | # bytes or Unicode strings. This should be used only with the |
| 1438 | # STRING, BINSTRING and SHORT_BINSTRING opcodes. |
| 1439 | if self.encoding == "bytes": |
| 1440 | return value |
| 1441 | else: |
| 1442 | return value.decode(self.encoding, self.errors) |
| 1443 | |
| 1444 | def load_string(self): |
| 1445 | data = self.readline()[:-1] |
no test coverage detected