From 14f8b4cfcb98de74b9c6e9316539be9e2a5cd31f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20v=2E=20L=C3=B6wis?= Date: Thu, 13 Jun 2002 20:33:02 +0000 Subject: Patch #568124: Add doc string macros. --- Modules/_weakref.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'Modules/_weakref.c') diff --git a/Modules/_weakref.c b/Modules/_weakref.c index f797fbf00e..31e63d1859 100644 --- a/Modules/_weakref.c +++ b/Modules/_weakref.c @@ -5,9 +5,9 @@ ((PyWeakReference **) PyObject_GET_WEAKREFS_LISTPTR(o)) -static char weakref_getweakrefcount__doc__[] = +PyDoc_STRVAR(weakref_getweakrefcount__doc__, "getweakrefcount(object) -- return the number of weak references\n" -"to 'object'."; +"to 'object'."); static PyObject * weakref_getweakrefcount(PyObject *self, PyObject *object) @@ -26,9 +26,9 @@ weakref_getweakrefcount(PyObject *self, PyObject *object) } -static char weakref_getweakrefs__doc__[] = +PyDoc_STRVAR(weakref_getweakrefs__doc__, "getweakrefs(object) -- return a list of all weak reference objects\n" -"that point to 'object'."; +"that point to 'object'."); static PyObject * weakref_getweakrefs(PyObject *self, PyObject *object) @@ -57,10 +57,10 @@ weakref_getweakrefs(PyObject *self, PyObject *object) } -static char weakref_ref__doc__[] = +PyDoc_STRVAR(weakref_ref__doc__, "new(object[, callback]) -- create a weak reference to 'object';\n" "when 'object' is finalized, 'callback' will be called and passed\n" -"a reference to 'object'."; +"a reference to 'object'."); static PyObject * weakref_ref(PyObject *self, PyObject *args) @@ -76,10 +76,10 @@ weakref_ref(PyObject *self, PyObject *args) } -static char weakref_proxy__doc__[] = +PyDoc_STRVAR(weakref_proxy__doc__, "proxy(object[, callback]) -- create a proxy object that weakly\n" "references 'object'. 'callback', if given, is called with a\n" -"reference to the proxy when it is about to be finalized."; +"reference to the proxy when it is about to be finalized."); static PyObject * weakref_proxy(PyObject *self, PyObject *args) -- cgit v1.2.1