From a320fd308c9c8ac4775f83d2b8edb9af90192741 Mon Sep 17 00:00:00 2001 From: Guido van Rossum Date: Thu, 9 Mar 1995 12:14:15 +0000 Subject: [PATCH] changes for MPW --- Modules/arraymodule.c | 2 +- Modules/audioop.c | 2 +- Modules/md5module.c | 2 +- Modules/rotormodule.c | 4 ++-- Modules/stdwinmodule.c | 8 ++++---- Modules/timemodule.c | 4 ++++ 6 files changed, 13 insertions(+), 9 deletions(-) diff --git a/Modules/arraymodule.c b/Modules/arraymodule.c index 6c377dc4140..d1c73069c5d 100644 --- a/Modules/arraymodule.c +++ b/Modules/arraymodule.c @@ -1072,7 +1072,7 @@ static sequence_methods array_as_sequence = { (intintobjargproc)array_ass_slice, /*sq_ass_slice*/ }; -static typeobject Arraytype = { +statichere typeobject Arraytype = { OB_HEAD_INIT(&Typetype) 0, "array", diff --git a/Modules/audioop.c b/Modules/audioop.c index f866e98941c..899bbc62b1b 100644 --- a/Modules/audioop.c +++ b/Modules/audioop.c @@ -35,7 +35,7 @@ OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. #endif #endif -#include +#include "mymath.h" /* Code shamelessly stolen from sox, ** (c) Craig Reese, Joe Campbell and Jeff Poskanzer 1989 */ diff --git a/Modules/md5module.c b/Modules/md5module.c index bb98cc229d2..f3b86ed040c 100644 --- a/Modules/md5module.c +++ b/Modules/md5module.c @@ -141,7 +141,7 @@ md5_getattr(self, name) return findmethod(md5_methods, (object *)self, name); } -static typeobject MD5type = { +statichere typeobject MD5type = { OB_HEAD_INIT(&Typetype) 0, /*ob_size*/ "md5", /*tp_name*/ diff --git a/Modules/rotormodule.c b/Modules/rotormodule.c index 60d92571798..6988f881a51 100644 --- a/Modules/rotormodule.c +++ b/Modules/rotormodule.c @@ -57,7 +57,7 @@ NOTE: you MUST use the SAME key in rotor.newrotor() #include "Python.h" -#include +#include "mymath.h" #define TRUE 1 #define FALSE 0 @@ -755,7 +755,7 @@ PyRotor_GetAttr(s, name) return Py_FindMethod(PyRotor_Methods, (PyObject * ) s, name); } -static PyTypeObject PyRotor_Type = { +statichere PyTypeObject PyRotor_Type = { PyObject_HEAD_INIT(&PyType_Type) 0, /*ob_size*/ "rotor", /*tp_name*/ diff --git a/Modules/stdwinmodule.c b/Modules/stdwinmodule.c index b256695bb4d..675b959b7b9 100644 --- a/Modules/stdwinmodule.c +++ b/Modules/stdwinmodule.c @@ -1141,7 +1141,7 @@ text_setattr(tp, name, v) return dictinsert(tp->t_attr, name, v); } -static typeobject Texttype = { +statichere typeobject Texttype = { OB_HEAD_INIT(&Typetype) 0, /*ob_size*/ "textedit", /*tp_name*/ @@ -1348,7 +1348,7 @@ menu_setattr(mp, name, v) return dictinsert(mp->m_attr, name, v); } -static typeobject Menutype = { +statichere typeobject Menutype = { OB_HEAD_INIT(&Typetype) 0, /*ob_size*/ "menu", /*tp_name*/ @@ -1505,7 +1505,7 @@ bitmap_setattr(bp, name, v) return dictinsert(bp->b_attr, name, v); } -static typeobject Bitmaptype = { +statichere typeobject Bitmaptype = { OB_HEAD_INIT(&Typetype) 0, /*ob_size*/ "bitmap", /*tp_name*/ @@ -1929,7 +1929,7 @@ window_setattr(wp, name, v) return dictinsert(wp->w_attr, name, v); } -static typeobject Windowtype = { +statichere typeobject Windowtype = { OB_HEAD_INIT(&Typetype) 0, /*ob_size*/ "window", /*tp_name*/ diff --git a/Modules/timemodule.c b/Modules/timemodule.c index 0702f276c5b..90a10eb8a0d 100644 --- a/Modules/timemodule.c +++ b/Modules/timemodule.c @@ -336,8 +336,12 @@ floattime() set an exception; else return 0. */ static int +#ifdef MPW +floatsleep(double secs) +#else floatsleep(secs) double secs; +#endif /* MPW */ { #ifdef HAVE_SELECT struct timeval t;