diff options
author | Andrew M. Kuchling <amk@amk.ca> | 2000-08-03 02:34:44 (GMT) |
---|---|---|
committer | Andrew M. Kuchling <amk@amk.ca> | 2000-08-03 02:34:44 (GMT) |
commit | a1abb728bc0d3898539ea89effa7906a50366f1a (patch) | |
tree | 91b7f25e125d8c550fa277e32023a2a39a249619 /Modules/threadmodule.c | |
parent | 767bf49b6b3d8825cfa5c52c2e8019bd23429fcd (diff) | |
download | cpython-a1abb728bc0d3898539ea89effa7906a50366f1a.zip cpython-a1abb728bc0d3898539ea89effa7906a50366f1a.tar.gz cpython-a1abb728bc0d3898539ea89effa7906a50366f1a.tar.bz2 |
Use METH_OLDARGS instead of numeric constant 0 in method def. tables
Diffstat (limited to 'Modules/threadmodule.c')
-rw-r--r-- | Modules/threadmodule.c | 38 |
1 files changed, 22 insertions, 16 deletions
diff --git a/Modules/threadmodule.c b/Modules/threadmodule.c index 5d0de4a..a625146 100644 --- a/Modules/threadmodule.c +++ b/Modules/threadmodule.c @@ -141,12 +141,18 @@ static char locked_doc[] = Return whether the lock is in the locked state."; static PyMethodDef lock_methods[] = { - {"acquire_lock", (PyCFunction)lock_PyThread_acquire_lock, 0, acquire_doc}, - {"acquire", (PyCFunction)lock_PyThread_acquire_lock, 0, acquire_doc}, - {"release_lock", (PyCFunction)lock_PyThread_release_lock, 0, release_doc}, - {"release", (PyCFunction)lock_PyThread_release_lock, 0, release_doc}, - {"locked_lock", (PyCFunction)lock_locked_lock, 0, locked_doc}, - {"locked", (PyCFunction)lock_locked_lock, 0, locked_doc}, + {"acquire_lock", (PyCFunction)lock_PyThread_acquire_lock, + METH_OLDARGS, acquire_doc}, + {"acquire", (PyCFunction)lock_PyThread_acquire_lock, + METH_OLDARGS, acquire_doc}, + {"release_lock", (PyCFunction)lock_PyThread_release_lock, + METH_OLDARGS, release_doc}, + {"release", (PyCFunction)lock_PyThread_release_lock, + METH_OLDARGS, release_doc}, + {"locked_lock", (PyCFunction)lock_locked_lock, + METH_OLDARGS, locked_doc}, + {"locked", (PyCFunction)lock_locked_lock, + METH_OLDARGS, locked_doc}, {NULL, NULL} /* sentinel */ }; @@ -343,16 +349,16 @@ static PyMethodDef thread_methods[] = { {"start_new", (PyCFunction)thread_PyThread_start_new_thread, METH_VARARGS, start_new_doc}, - {"allocate_lock", (PyCFunction)thread_PyThread_allocate_lock, 0, - allocate_doc}, - {"allocate", (PyCFunction)thread_PyThread_allocate_lock, 0, - allocate_doc}, - {"exit_thread", (PyCFunction)thread_PyThread_exit_thread, 0, - exit_doc}, - {"exit", (PyCFunction)thread_PyThread_exit_thread, 0, - exit_doc}, - {"get_ident", (PyCFunction)thread_get_ident, 0, - get_ident_doc}, + {"allocate_lock", (PyCFunction)thread_PyThread_allocate_lock, + METH_OLDARGS, allocate_doc}, + {"allocate", (PyCFunction)thread_PyThread_allocate_lock, + METH_OLDARGS, allocate_doc}, + {"exit_thread", (PyCFunction)thread_PyThread_exit_thread, + METH_OLDARGS, exit_doc}, + {"exit", (PyCFunction)thread_PyThread_exit_thread, + METH_OLDARGS, exit_doc}, + {"get_ident", (PyCFunction)thread_get_ident, + METH_OLDARGS, get_ident_doc}, #ifndef NO_EXIT_PROG {"exit_prog", (PyCFunction)thread_PyThread_exit_prog}, #endif |