"Compiling" version

This commit is contained in:
Guido van Rossum 1990-12-20 15:06:42 +00:00
parent 226d79eb4a
commit 3f5da24ea3
72 changed files with 3363 additions and 2061 deletions

View file

@ -33,8 +33,8 @@ def err(args):
#
def getnum(s):
n = ''
while s[:1] in digits:
n = n + s[:1]
while s and s[0] in digits:
n = n + s[0]
s = s[1:]
return n, s

View file

@ -25,24 +25,13 @@ Each definition must be contained on one line:
N*retval
*/
#include <stdio.h>
#include <gl.h>
#include <device.h>
#include "PROTO.h"
#include "object.h"
#include "intobject.h"
#include "floatobject.h"
#include "listobject.h"
#include "tupleobject.h"
#include "dictobject.h"
#include "methodobject.h"
#include "moduleobject.h"
#include "objimpl.h"
#include "allobjects.h"
#include "import.h"
#include "sigtype.h"
#include "modsupport.h"
#include "cgensupport.h"
#include "errors.h"
/*
Some stubs are too complicated for the stub generator.

View file

@ -1,20 +1,11 @@
/* Math module -- standard C math library functions, pi and e */
#include <stdio.h>
#include <math.h>
#include "allobjects.h"
#include "PROTO.h"
#include "object.h"
#include "intobject.h"
#include "tupleobject.h"
#include "floatobject.h"
#include "dictobject.h"
#include "methodobject.h"
#include "moduleobject.h"
#include "objimpl.h"
#include "import.h"
#include "modsupport.h"
#include <math.h>
static int
getdoublearg(args, px)
register object *args;

View file

@ -1,6 +1,5 @@
/* POSIX module implementation */
#include <stdio.h>
#include <signal.h>
#include <string.h>
#include <setjmp.h>
@ -14,20 +13,8 @@
#include <sys/dir.h>
#endif
#include "PROTO.h"
#include "object.h"
#include "intobject.h"
#include "stringobject.h"
#include "tupleobject.h"
#include "listobject.h"
#include "dictobject.h"
#include "methodobject.h"
#include "moduleobject.h"
#include "objimpl.h"
#include "import.h"
#include "sigtype.h"
#include "allobjects.h"
#include "modsupport.h"
#include "errors.h"
extern char *strerror PROTO((int));
@ -140,7 +127,6 @@ posix_do_stat(self, args, statfunc)
v = newtupleobject(10);
if (v == NULL)
return NULL;
errno = 0;
#define SET(i, st_member) settupleitem(v, i, newintobject((long)st.st_member))
SET(0, st_mode);
SET(1, st_ino);
@ -153,9 +139,9 @@ posix_do_stat(self, args, statfunc)
SET(8, st_mtime);
SET(9, st_ctime);
#undef SET
if (errno != 0) {
if (err_occurred()) {
DECREF(v);
return err_nomem();
return NULL;
}
return v;
}
@ -335,6 +321,8 @@ posix_utimes(self, args)
#ifdef NO_GETCWD
#include "errno.h"
/* Quick hack to get posix.getcwd() working for pure BSD 4.3 */
/* XXX This assumes MAXPATHLEN = 1024 !!! */

View file

@ -38,22 +38,11 @@
XXX more?
*/
#include <stdio.h>
#include "stdwin.h"
#include "allobjects.h"
#include "PROTO.h"
#include "object.h"
#include "intobject.h"
#include "stringobject.h"
#include "tupleobject.h"
#include "dictobject.h"
#include "methodobject.h"
#include "moduleobject.h"
#include "objimpl.h"
#include "import.h"
#include "modsupport.h"
#include "errors.h"
#include "stdwin.h"
/* Window and menu object types declared here because of forward references */

View file

@ -1,6 +1,11 @@
/* Time module */
#include <stdio.h>
#include "allobjects.h"
#include "modsupport.h"
#include "sigtype.h"
#include <signal.h>
#include <setjmp.h>
@ -11,18 +16,6 @@ typedef unsigned long time_t;
extern time_t time();
#endif /* !__STDC__ */
#include "PROTO.h"
#include "object.h"
#include "intobject.h"
#include "dictobject.h"
#include "methodobject.h"
#include "moduleobject.h"
#include "objimpl.h"
#include "import.h"
#include "sigtype.h"
#include "modsupport.h"
#include "errors.h"
/* Time methods */