Home | History | Annotate | Download | only in Modules

Lines Matching defs:PROTO

75 #define PROTO    '\x80' /* identify pickle protocol */

342 int proto;
344 /* bool, true if proto > 0 */
1013 if (self->proto >= 2) {
1083 if (self->proto >= 2) {
1161 /* proto < 2: write the repr and newline. This is quadratic-time
1525 if (self->proto) {
1551 if (len <= 3 && self->proto >= 2) {
1572 /* proto < 2 and len > 0, or proto >= 2 and len > 3.
1632 if (self->proto == 0) {
1651 /* proto > 0: write in batches of BATCHSIZE. */
1800 if (self->proto == 0) {
1826 /* proto
1930 assert(self->proto > 0);
2009 if (PyDict_CheckExact(args) && self->proto > 0) {
2234 if (self->proto >= 2) {
2393 int use_newobj = self->proto >= 2;
2755 t = PyInt_FromLong(self->proto);
2816 if (self->proto >= 2) {
2819 bytes[0] = PROTO;
2820 assert(self->proto >= 0 && self->proto < 256);
2821 bytes[1] = (char)self->proto;
3018 newPicklerobject(PyObject *file, int proto)
3022 if (proto < 0)
3023 proto = HIGHEST_PROTOCOL;
3024 if (proto > HIGHEST_PROTOCOL) {
3027 proto, HIGHEST_PROTOCOL);
3034 self->proto = proto;
3035 self->bin = proto > 0;
3128 int proto = 0;
3137 if (!PyArg_ParseTuple(args, "|i:Pickler", &proto)) {
3139 proto = 0;
3141 kwlist, &file, &proto))
3144 return (PyObject *)newPicklerobject(file, proto);
4568 * slot state dict too (a proto 2 addition).
4683 /* Just raises an error if we don't know the protocol specified. PROTO
4971 case PROTO:
5389 case PROTO:
5681 int proto = 0;
5684 &ob, &file, &proto)))
5687 if (!( pickler = newPicklerobject(file, proto)))
5710 int proto = 0;
5713 &ob, &proto)))
5719 if (!( pickler = newPicklerobject(file, proto)))
5814 "See the Pickler docstring for the meaning of optional argument proto.")
5821 "See the Pickler docstring for the meaning of optional argument proto.")
5834 "The optional proto argument tells the pickler to use the given\n"