(self, value)
| 1320 | dispatch[BINFLOAT[0]] = load_binfloat |
| 1321 | |
| 1322 | def _decode_string(self, value): |
| 1323 | # Used to allow strings from Python 2 to be decoded either as |
| 1324 | # bytes or Unicode strings. This should be used only with the |
| 1325 | # STRING, BINSTRING and SHORT_BINSTRING opcodes. |
| 1326 | if self.encoding == "bytes": |
| 1327 | return value |
| 1328 | else: |
| 1329 | return value.decode(self.encoding, self.errors) |
| 1330 | |
| 1331 | def load_string(self): |
| 1332 | data = self.readline()[:-1] |
no test coverage detected