mirror of
https://github.com/python/cpython.git
synced 2025-07-18 16:55:20 +00:00
* Makefile: added all: and default: targets.
* many files: made some functions static; removed "extern int errno;". * frozenmain.c: fixed bugs introduced on 24 June... * flmodule.c: remove 1.5 bw compat hacks, add new functions in 2.2a (and some old functions that were omitted). * timemodule.c: added MSDOS floatsleep version . * pgenmain.c: changed exit() to goaway() and added defn of goaway(). * intrcheck.c: add hack (to UNIX only) so interrupting 3 times will exit from a hanging program. The second interrupt prints a message explaining this to the user.
This commit is contained in:
parent
9e90a672b4
commit
f1dc566328
16 changed files with 140 additions and 165 deletions
|
@ -1652,7 +1652,7 @@ locals_2_fast(f, clear)
|
|||
err_setval(error_type, error_value);
|
||||
}
|
||||
|
||||
void
|
||||
static void
|
||||
mergelocals()
|
||||
{
|
||||
locals_2_fast(current_frame, 1);
|
||||
|
|
|
@ -39,8 +39,7 @@ OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
|||
#include "structmember.h"
|
||||
|
||||
#include <ctype.h>
|
||||
|
||||
extern int errno;
|
||||
#include <errno.h>
|
||||
|
||||
#define OFF(x) offsetof(codeobject, x)
|
||||
|
||||
|
|
|
@ -59,9 +59,6 @@ OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
|||
#include "modsupport.h"
|
||||
|
||||
#include <errno.h>
|
||||
#ifndef errno
|
||||
extern int errno;
|
||||
#endif
|
||||
|
||||
#include "errcode.h"
|
||||
|
||||
|
|
|
@ -27,8 +27,6 @@ OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
|||
#include <math.h>
|
||||
#include <errno.h>
|
||||
|
||||
extern int errno;
|
||||
|
||||
double
|
||||
fmod(x, y)
|
||||
double x, y;
|
||||
|
|
|
@ -38,7 +38,6 @@ main(argc, argv)
|
|||
{
|
||||
char *p;
|
||||
int n, inspect, sts;
|
||||
int n;
|
||||
|
||||
if ((p = getenv("PYTHONDEBUG")) && *p != '\0')
|
||||
debugging = 1;
|
||||
|
@ -63,8 +62,7 @@ main(argc, argv)
|
|||
else
|
||||
sts = 0;
|
||||
|
||||
if (inspect && isatty((int)fileno(stdin)) &&
|
||||
(filename != NULL || command != NULL))
|
||||
if (inspect && isatty((int)fileno(stdin)))
|
||||
sts = run(stdin, "<stdin>") != 0;
|
||||
|
||||
goaway(sts);
|
||||
|
|
|
@ -30,8 +30,6 @@ OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
|||
#include <stdio.h>
|
||||
#include <errno.h>
|
||||
|
||||
extern int errno;
|
||||
|
||||
#ifndef NO_GETWD
|
||||
|
||||
/* Default: Version for BSD systems -- use getwd() */
|
||||
|
|
|
@ -34,7 +34,6 @@ OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
|||
#include "marshal.h"
|
||||
|
||||
#include <errno.h>
|
||||
extern int errno;
|
||||
|
||||
#define TYPE_NULL '0'
|
||||
#define TYPE_NONE 'N'
|
||||
|
|
|
@ -314,6 +314,8 @@ int getargs(va_alist) va_dcl
|
|||
return ok;
|
||||
}
|
||||
|
||||
#ifdef UNUSED
|
||||
|
||||
int
|
||||
getlongtuplearg(args, a, n)
|
||||
object *args;
|
||||
|
@ -394,6 +396,8 @@ getshortlistarg(args, a, n)
|
|||
return 1;
|
||||
}
|
||||
|
||||
#endif /* UNUSED */
|
||||
|
||||
|
||||
/* Generic function to create a value -- the inverse of getargs() */
|
||||
/* After an original idea and first implementation by Steven Miale */
|
||||
|
|
|
@ -284,7 +284,7 @@ run_file(fp, filename, start, globals, locals)
|
|||
return run_err_node(err, n, filename, globals, locals);
|
||||
}
|
||||
|
||||
object *
|
||||
static object *
|
||||
run_err_node(err, n, filename, globals, locals)
|
||||
int err;
|
||||
node *n;
|
||||
|
@ -298,7 +298,7 @@ run_err_node(err, n, filename, globals, locals)
|
|||
return run_node(n, filename, globals, locals);
|
||||
}
|
||||
|
||||
object *
|
||||
static object *
|
||||
run_node(n, filename, globals, locals)
|
||||
node *n;
|
||||
char *filename;
|
||||
|
@ -307,7 +307,7 @@ run_node(n, filename, globals, locals)
|
|||
return eval_node(n, filename, globals, locals);
|
||||
}
|
||||
|
||||
object *
|
||||
static object *
|
||||
eval_node(n, filename, globals, locals)
|
||||
node *n;
|
||||
char *filename;
|
||||
|
@ -392,7 +392,7 @@ fatal(msg)
|
|||
extern int threads_started;
|
||||
#endif
|
||||
|
||||
void
|
||||
static void
|
||||
cleanup()
|
||||
{
|
||||
object *exitfunc = sysget("exitfunc");
|
||||
|
@ -461,7 +461,7 @@ goaway(sts)
|
|||
}
|
||||
|
||||
#ifdef HANDLE_SIGNALS
|
||||
SIGTYPE
|
||||
static SIGTYPE
|
||||
sighandler(sig)
|
||||
int sig;
|
||||
{
|
||||
|
@ -472,7 +472,7 @@ sighandler(sig)
|
|||
}
|
||||
#endif
|
||||
|
||||
void
|
||||
static void
|
||||
initsigs()
|
||||
{
|
||||
initintr();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue