summaryrefslogtreecommitdiffstats
path: root/Modules/clinic/_pickle.c.h
diff options
context:
space:
mode:
authorLarry Hastings <larry@hastings.org>2014-01-28 13:00:08 (GMT)
committerLarry Hastings <larry@hastings.org>2014-01-28 13:00:08 (GMT)
commit581ee3618c756132359d98b6fc149ec7e7ca9ef9 (patch)
treefa211357051306722af3b064f5b095992105524c /Modules/clinic/_pickle.c.h
parenteecbbad89b60c20641fa8dd1c12f52b3648408ea (diff)
downloadcpython-581ee3618c756132359d98b6fc149ec7e7ca9ef9.zip
cpython-581ee3618c756132359d98b6fc149ec7e7ca9ef9.tar.gz
cpython-581ee3618c756132359d98b6fc149ec7e7ca9ef9.tar.bz2
Issue #20326: Argument Clinic now uses a simple, unique signature to
annotate text signatures in docstrings, resulting in fewer false positives. "self" parameters are also explicitly marked, allowing inspect.Signature() to authoritatively detect (and skip) said parameters. Issue #20326: Argument Clinic now generates separate checksums for the input and output sections of the block, allowing external tools to verify that the input has not changed (and thus the output is not out-of-date).
Diffstat (limited to 'Modules/clinic/_pickle.c.h')
-rw-r--r--Modules/clinic/_pickle.c.h34
1 files changed, 17 insertions, 17 deletions
diff --git a/Modules/clinic/_pickle.c.h b/Modules/clinic/_pickle.c.h
index 12dc2ed..9ef469d 100644
--- a/Modules/clinic/_pickle.c.h
+++ b/Modules/clinic/_pickle.c.h
@@ -3,7 +3,7 @@ preserve
[clinic start generated code]*/
PyDoc_STRVAR(_pickle_Pickler_clear_memo__doc__,
-"clear_memo(self)\n"
+"sig=($self)\n"
"Clears the pickler\'s \"memo\".\n"
"\n"
"The memo is the data structure that remembers which objects the\n"
@@ -24,14 +24,14 @@ _pickle_Pickler_clear_memo(PicklerObject *self, PyObject *Py_UNUSED(ignored))
}
PyDoc_STRVAR(_pickle_Pickler_dump__doc__,
-"dump(self, obj)\n"
+"sig=($self, obj)\n"
"Write a pickled representation of the given object to the open file.");
#define _PICKLE_PICKLER_DUMP_METHODDEF \
{"dump", (PyCFunction)_pickle_Pickler_dump, METH_O, _pickle_Pickler_dump__doc__},
PyDoc_STRVAR(_pickle_Pickler___init____doc__,
-"Pickler(file, protocol=None, fix_imports=True)\n"
+"sig=(file, protocol=None, fix_imports=True)\n"
"This takes a binary file for writing a pickle data stream.\n"
"\n"
"The optional *protocol* argument tells the pickler to use the given\n"
@@ -74,7 +74,7 @@ exit:
}
PyDoc_STRVAR(_pickle_PicklerMemoProxy_clear__doc__,
-"clear(self)\n"
+"sig=($self)\n"
"Remove all items from memo.");
#define _PICKLE_PICKLERMEMOPROXY_CLEAR_METHODDEF \
@@ -90,7 +90,7 @@ _pickle_PicklerMemoProxy_clear(PicklerMemoProxyObject *self, PyObject *Py_UNUSED
}
PyDoc_STRVAR(_pickle_PicklerMemoProxy_copy__doc__,
-"copy(self)\n"
+"sig=($self)\n"
"Copy the memo to a new object.");
#define _PICKLE_PICKLERMEMOPROXY_COPY_METHODDEF \
@@ -106,7 +106,7 @@ _pickle_PicklerMemoProxy_copy(PicklerMemoProxyObject *self, PyObject *Py_UNUSED(
}
PyDoc_STRVAR(_pickle_PicklerMemoProxy___reduce____doc__,
-"__reduce__(self)\n"
+"sig=($self)\n"
"Implement pickle support.");
#define _PICKLE_PICKLERMEMOPROXY___REDUCE___METHODDEF \
@@ -122,7 +122,7 @@ _pickle_PicklerMemoProxy___reduce__(PicklerMemoProxyObject *self, PyObject *Py_U
}
PyDoc_STRVAR(_pickle_Unpickler_load__doc__,
-"load(self)\n"
+"sig=($self)\n"
"Load a pickle.\n"
"\n"
"Read a pickled object representation from the open file object given\n"
@@ -142,7 +142,7 @@ _pickle_Unpickler_load(UnpicklerObject *self, PyObject *Py_UNUSED(ignored))
}
PyDoc_STRVAR(_pickle_Unpickler_find_class__doc__,
-"find_class(self, module_name, global_name)\n"
+"sig=($self, module_name, global_name)\n"
"Return an object from a specified module.\n"
"\n"
"If necessary, the module will be imported. Subclasses may override\n"
@@ -176,7 +176,7 @@ exit:
}
PyDoc_STRVAR(_pickle_Unpickler___init____doc__,
-"Unpickler(file, *, fix_imports=True, encoding=\'ASCII\', errors=\'strict\')\n"
+"sig=(file, *, fix_imports=True, encoding=\'ASCII\', errors=\'strict\')\n"
"This takes a binary file for reading a pickle data stream.\n"
"\n"
"The protocol version of the pickle is detected automatically, so no\n"
@@ -222,7 +222,7 @@ exit:
}
PyDoc_STRVAR(_pickle_UnpicklerMemoProxy_clear__doc__,
-"clear(self)\n"
+"sig=($self)\n"
"Remove all items from memo.");
#define _PICKLE_UNPICKLERMEMOPROXY_CLEAR_METHODDEF \
@@ -238,7 +238,7 @@ _pickle_UnpicklerMemoProxy_clear(UnpicklerMemoProxyObject *self, PyObject *Py_UN
}
PyDoc_STRVAR(_pickle_UnpicklerMemoProxy_copy__doc__,
-"copy(self)\n"
+"sig=($self)\n"
"Copy the memo to a new object.");
#define _PICKLE_UNPICKLERMEMOPROXY_COPY_METHODDEF \
@@ -254,7 +254,7 @@ _pickle_UnpicklerMemoProxy_copy(UnpicklerMemoProxyObject *self, PyObject *Py_UNU
}
PyDoc_STRVAR(_pickle_UnpicklerMemoProxy___reduce____doc__,
-"__reduce__(self)\n"
+"sig=($self)\n"
"Implement pickling support.");
#define _PICKLE_UNPICKLERMEMOPROXY___REDUCE___METHODDEF \
@@ -270,7 +270,7 @@ _pickle_UnpicklerMemoProxy___reduce__(UnpicklerMemoProxyObject *self, PyObject *
}
PyDoc_STRVAR(_pickle_dump__doc__,
-"dump(module, obj, file, protocol=None, *, fix_imports=True)\n"
+"sig=($module, obj, file, protocol=None, *, fix_imports=True)\n"
"Write a pickled representation of obj to the open file object file.\n"
"\n"
"This is equivalent to ``Pickler(file, protocol).dump(obj)``, but may\n"
@@ -320,7 +320,7 @@ exit:
}
PyDoc_STRVAR(_pickle_dumps__doc__,
-"dumps(module, obj, protocol=None, *, fix_imports=True)\n"
+"sig=($module, obj, protocol=None, *, fix_imports=True)\n"
"Return the pickled representation of the object as a bytes object.\n"
"\n"
"The optional *protocol* argument tells the pickler to use the given\n"
@@ -361,7 +361,7 @@ exit:
}
PyDoc_STRVAR(_pickle_load__doc__,
-"load(module, file, *, fix_imports=True, encoding=\'ASCII\', errors=\'strict\')\n"
+"sig=($module, file, *, fix_imports=True, encoding=\'ASCII\', errors=\'strict\')\n"
"Read and return an object from the pickle data stored in a file.\n"
"\n"
"This is equivalent to ``Unpickler(file).load()``, but may be more\n"
@@ -413,7 +413,7 @@ exit:
}
PyDoc_STRVAR(_pickle_loads__doc__,
-"loads(module, data, *, fix_imports=True, encoding=\'ASCII\', errors=\'strict\')\n"
+"sig=($module, data, *, fix_imports=True, encoding=\'ASCII\', errors=\'strict\')\n"
"Read and return an object from the given pickle data.\n"
"\n"
"The protocol version of the pickle is detected automatically, so no\n"
@@ -454,4 +454,4 @@ _pickle_loads(PyModuleDef *module, PyObject *args, PyObject *kwargs)
exit:
return return_value;
}
-/*[clinic end generated code: checksum=b7a2e1df72bdbc87da3cd0e43a3caa1a879892bb]*/
+/*[clinic end generated code: output=c59d4dafc2646f11 input=a9049054013a1b77]*/