Kaydet (Commit) 286da3b4 authored tarafından Peter Schneider-Kamp's avatar Peter Schneider-Kamp

ANSI-fying

added excplicit node * parameter to termvalid argument in
validate_two_chain_ops of parsermodule.c (as proposed by fred)
üst 41c36ffe
...@@ -265,7 +265,6 @@ Sleep(int milli) ...@@ -265,7 +265,6 @@ Sleep(int milli)
{ {
/* XXX Too bad if you don't have select(). */ /* XXX Too bad if you don't have select(). */
struct timeval t; struct timeval t;
double frac;
t.tv_sec = milli/1000; t.tv_sec = milli/1000;
t.tv_usec = (milli%1000) * 1000; t.tv_usec = (milli%1000) * 1000;
select(0, (fd_set *)0, (fd_set *)0, (fd_set *)0, &t); select(0, (fd_set *)0, (fd_set *)0, (fd_set *)0, &t);
...@@ -1503,7 +1502,6 @@ static PyObject * ...@@ -1503,7 +1502,6 @@ static PyObject *
Tkapp_DeleteFileHandler(PyObject *self, PyObject *args) Tkapp_DeleteFileHandler(PyObject *self, PyObject *args)
{ {
PyObject *file; PyObject *file;
FileHandler_ClientData *data;
int tfile; int tfile;
if (!PyArg_ParseTuple(args, "O:deletefilehandler", &file)) if (!PyArg_ParseTuple(args, "O:deletefilehandler", &file))
......
...@@ -47,8 +47,7 @@ newmd5object() ...@@ -47,8 +47,7 @@ newmd5object()
/* MD5 methods */ /* MD5 methods */
static void static void
md5_dealloc(md5p) md5_dealloc(md5object *md5p)
md5object *md5p;
{ {
PyObject_Del(md5p); PyObject_Del(md5p);
} }
...@@ -57,9 +56,7 @@ md5_dealloc(md5p) ...@@ -57,9 +56,7 @@ md5_dealloc(md5p)
/* MD5 methods-as-attributes */ /* MD5 methods-as-attributes */
static PyObject * static PyObject *
md5_update(self, args) md5_update(md5object *self, PyObject *args)
md5object *self;
PyObject *args;
{ {
unsigned char *cp; unsigned char *cp;
int len; int len;
...@@ -82,9 +79,7 @@ arguments."; ...@@ -82,9 +79,7 @@ arguments.";
static PyObject * static PyObject *
md5_digest(self, args) md5_digest(md5object *self, PyObject *args)
md5object *self;
PyObject *args;
{ {
MD5_CTX mdContext; MD5_CTX mdContext;
...@@ -109,9 +104,7 @@ including null bytes."; ...@@ -109,9 +104,7 @@ including null bytes.";
static PyObject * static PyObject *
md5_copy(self, args) md5_copy(md5object *self, PyObject *args)
md5object *self;
PyObject *args;
{ {
md5object *md5p; md5object *md5p;
...@@ -140,9 +133,7 @@ static PyMethodDef md5_methods[] = { ...@@ -140,9 +133,7 @@ static PyMethodDef md5_methods[] = {
}; };
static PyObject * static PyObject *
md5_getattr(self, name) md5_getattr(md5object *self, char *name)
md5object *self;
char *name;
{ {
return Py_FindMethod(md5_methods, (PyObject *)self, name); return Py_FindMethod(md5_methods, (PyObject *)self, name);
} }
...@@ -208,9 +199,7 @@ statichere PyTypeObject MD5type = { ...@@ -208,9 +199,7 @@ statichere PyTypeObject MD5type = {
/* MD5 functions */ /* MD5 functions */
static PyObject * static PyObject *
MD5_new(self, args) MD5_new(PyObject *self, PyObject *args)
PyObject *self;
PyObject *args;
{ {
md5object *md5p; md5object *md5p;
unsigned char *cp = NULL; unsigned char *cp = NULL;
......
...@@ -477,9 +477,7 @@ parser_methods[] = { ...@@ -477,9 +477,7 @@ parser_methods[] = {
static PyObject* static PyObject*
parser_getattr(self, name) parser_getattr(PyObject *self, char *name)
PyObject *self;
char *name;
{ {
return (Py_FindMethod(parser_methods, self, name)); return (Py_FindMethod(parser_methods, self, name));
} }
...@@ -491,8 +489,7 @@ parser_getattr(self, name) ...@@ -491,8 +489,7 @@ parser_getattr(self, name)
* *
*/ */
static void static void
err_string(message) err_string(char *message)
char *message;
{ {
PyErr_SetString(parser_error, message); PyErr_SetString(parser_error, message);
} }
...@@ -1632,8 +1629,7 @@ validate_for(node *tree) ...@@ -1632,8 +1629,7 @@ validate_for(node *tree)
* *
*/ */
static int static int
validate_try(tree) validate_try(node *tree)
node *tree;
{ {
int nch = NCH(tree); int nch = NCH(tree);
int pos = 3; int pos = 3;
...@@ -1882,11 +1878,7 @@ validate_and_expr(node *tree) ...@@ -1882,11 +1878,7 @@ validate_and_expr(node *tree)
static int static int
validate_chain_two_ops(tree, termvalid, op1, op2) validate_chain_two_ops(node *tree, int (*termvalid)(node *), int op1, int op2)
node *tree;
int (*termvalid)();
int op1;
int op2;
{ {
int pos = 1; int pos = 1;
int nch = NCH(tree); int nch = NCH(tree);
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment