Permalink
Browse files

Fix C prototype warnings.

  • Loading branch information...
1 parent b8a3111 commit a39190a95ba552e8946ec49b6f6b1fd04afe27a3 Lenna Peterson committed with peterjc Mar 21, 2012
Showing with 9 additions and 8 deletions.
  1. +4 −2 Bio/PDB/mmCIF/MMCIFlexmodule.c
  2. +3 −3 Bio/PDB/mmCIF/lex.yy.c
  3. +2 −3 Bio/PDB/mmCIF/mmcif.lex
@@ -1,6 +1,6 @@
#include <Python.h>
-char *mmcif_get_string(void);
+extern char *mmcif_get_string(void);
FILE *fp;
@@ -13,6 +13,7 @@ static PyObject *MMCIFlex_open_file(PyObject *self, PyObject *args)
fp=fopen(filename, "r");
+ extern void mmcif_set_file(FILE *fp);
mmcif_set_file(fp);
Py_INCREF(Py_None);
@@ -41,6 +42,7 @@ static PyObject *MMCIFlex_get_token(PyObject *self, PyObject *args)
char *value="";
/* get token number */
+ extern int mmcif_get_token(void);
flag=mmcif_get_token();
/* if flag==0 we are EOF */
@@ -63,7 +65,7 @@ static PyMethodDef MMCIFlexMethods[]=
};
-void initMMCIFlex()
+void initMMCIFlex(void)
{
(void) Py_InitModule("MMCIFlex", MMCIFlexMethods);
}
View
@@ -1839,13 +1839,15 @@ void yyfree (void * ptr )
+
void mmcif_set_file(FILE *fp)
{
yyin=fp;
}
-int mmcif_get_token()
+int mmcif_get_token(void)
{
+ extern int yylex(void);
return yylex();
}
@@ -1855,5 +1857,3 @@ char *mmcif_get_string(void)
}
-
-
View
@@ -49,8 +49,9 @@ void mmcif_set_file(FILE *fp)
yyin=fp;
}
-int mmcif_get_token()
+int mmcif_get_token(void)
{
+ extern int yylex(void);
return yylex();
}
@@ -59,5 +60,3 @@ char *mmcif_get_string(void)
return yytext;
}
-
-

0 comments on commit a39190a

Please sign in to comment.