g2c.hin, [...]: Kill VOID, Void and Int.

* g2c.hin, libF77/d_cnjg.c, libF77/main.c, libF77/r_cnjg.c,
	libF77/s_cat.c, libF77/s_paus.c, libF77/s_rnge.c, libF77/setarg.c,
	libF77/setsig.c, libF77/signal1.h0, libI77/dfe.c, libI77/due.c,
	libI77/err.c, libI77/fio.h, libI77/fmt.c, libI77/iio.c,
	libI77/ilnw.c, libI77/lread.c, libI77/lwrite.c, libI77/rsfe.c,
	libI77/rsli.c, libI77/rsne.c, libI77/sfe.c, libI77/sue.c,
	libI77/util.c, libI77/wrtfmt.c, libI77/wsfe.c, libI77/wsle.c,
	libI77/xwsne.c, libU77/date_.c: Kill VOID, Void and Int.

From-SVN: r54134
This commit is contained in:
Kaveh R. Ghazi 2002-06-01 01:58:10 +00:00 committed by Kaveh Ghazi
parent 9321813126
commit 9bb2ada61f
31 changed files with 105 additions and 109 deletions

View File

@ -1,3 +1,14 @@
Fri May 31 21:56:30 2002 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* g2c.hin, libF77/d_cnjg.c, libF77/main.c, libF77/r_cnjg.c,
libF77/s_cat.c, libF77/s_paus.c, libF77/s_rnge.c, libF77/setarg.c,
libF77/setsig.c, libF77/signal1.h0, libI77/dfe.c, libI77/due.c,
libI77/err.c, libI77/fio.h, libI77/fmt.c, libI77/iio.c,
libI77/ilnw.c, libI77/lread.c, libI77/lwrite.c, libI77/rsfe.c,
libI77/rsli.c, libI77/rsne.c, libI77/sfe.c, libI77/sue.c,
libI77/util.c, libI77/wrtfmt.c, libI77/wsfe.c, libI77/wsle.c,
libI77/xwsne.c, libU77/date_.c: Kill VOID, Void and Int.
Fri May 31 21:54:37 2002 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* libF77/F77_aloc.c, libF77/exit_.c, libF77/main.c,

View File

@ -132,8 +132,6 @@ typedef struct
ftnlen inblanklen;
} inlist;
#define VOID void
union Multitype { /* for multiple entry points */
integer1 g;
shortint h;
@ -183,11 +181,11 @@ typedef shortint (*J_fp)(...);
typedef integer (*I_fp)(...);
typedef real (*R_fp)(...);
typedef doublereal (*D_fp)(...), (*E_fp)(...);
typedef /* Complex */ VOID (*C_fp)(...);
typedef /* Double Complex */ VOID (*Z_fp)(...);
typedef /* Complex */ void (*C_fp)(...);
typedef /* Double Complex */ void (*Z_fp)(...);
typedef logical (*L_fp)(...);
typedef shortlogical (*K_fp)(...);
typedef /* Character */ VOID (*H_fp)(...);
typedef /* Character */ void (*H_fp)(...);
typedef /* Subroutine */ int (*S_fp)(...);
#else
typedef int /* Unknown procedure type */ (*U_fp)();
@ -195,17 +193,17 @@ typedef shortint (*J_fp)();
typedef integer (*I_fp)();
typedef real (*R_fp)();
typedef doublereal (*D_fp)(), (*E_fp)();
typedef /* Complex */ VOID (*C_fp)();
typedef /* Double Complex */ VOID (*Z_fp)();
typedef /* Complex */ void (*C_fp)();
typedef /* Double Complex */ void (*Z_fp)();
typedef logical (*L_fp)();
typedef shortlogical (*K_fp)();
typedef /* Character */ VOID (*H_fp)();
typedef /* Character */ void (*H_fp)();
typedef /* Subroutine */ int (*S_fp)();
#endif
/* E_fp is for real functions when -R is not specified */
typedef VOID C_f; /* complex function */
typedef VOID H_f; /* character function */
typedef VOID Z_f; /* double complex function */
typedef void C_f; /* complex function */
typedef void H_f; /* character function */
typedef void Z_f; /* double complex function */
typedef doublereal E_f; /* real function with -R not specified */
/* undef any lower-case symbols that your C compiler predefines, e.g.: */

View File

@ -1,6 +1,6 @@
#include "f2c.h"
VOID
void
d_cnjg(doublecomplex *r, doublecomplex *z)
{
doublereal zi = z->i;

View File

@ -3,13 +3,8 @@
#include <stdio.h>
#include "signal1.h"
#undef VOID
#include <stdlib.h>
#ifndef VOID
#define VOID void
#endif
extern void f_exit(void);
#ifndef NO_ONEXIT
#define ONEXIT atexit

View File

@ -1,6 +1,7 @@
#include "f2c.h"
VOID r_cnjg(complex *r, complex *z)
void
r_cnjg(complex *r, complex *z)
{
real zi = z->i;
r->r = z->r;

View File

@ -14,7 +14,7 @@
#include <string.h>
#endif /* NO_OVERWRITE */
VOID
void
s_cat(char *lp, char *rpp[], ftnint rnp[], ftnint *np, ftnlen ll)
{
ftnlen i, nc;

View File

@ -3,23 +3,21 @@
#define PAUSESIG 15
#include "signal1.h"
#define Void void
#define Int int
#undef abs
#undef min
#undef max
#include <stdlib.h>
extern int getpid(void), isatty(int), pause(void);
extern VOID f_exit(Void);
extern void f_exit(void);
static VOID
static void
waitpause(Sigarg)
{ Use_Sigarg;
return;
}
static VOID
static void
s_1paus(FILE *fin)
{
fprintf(stderr,

View File

@ -3,7 +3,7 @@
/* called when a subscript is out of range */
extern VOID sig_die(char*,int);
extern void sig_die(char*,int);
integer s_rnge(char *varn, ftnint offset, char *procn, ftnint line)
{
register int i;

View File

@ -1,13 +1,8 @@
/* Set up the global argc/argv info for use by getarg_, iargc_, and
g77's inlined intrinsic equivalents. */
#undef VOID
#include <stdlib.h>
#ifndef VOID
#define VOID void
#endif
int f__xargc;
char **f__xargv;

View File

@ -9,31 +9,28 @@
#endif
#endif
#undef VOID
#include <stdlib.h>
#ifndef VOID
#define VOID void
#endif
extern void sig_die(char*, int);
#define Int int
static VOID sigfdie(Sigarg)
static void
sigfdie(Sigarg)
{
Use_Sigarg;
sig_die("Floating Exception", 1);
}
static VOID sigidie(Sigarg)
static void
sigidie(Sigarg)
{
Use_Sigarg;
sig_die("IOT Trap", 1);
}
#ifdef SIGQUIT
static VOID sigqdie(Sigarg)
static void
sigqdie(Sigarg)
{
Use_Sigarg;
sig_die("Quit signal", 1);
@ -41,20 +38,23 @@ sig_die("Quit signal", 1);
#endif
static VOID sigindie(Sigarg)
static void
sigindie(Sigarg)
{
Use_Sigarg;
sig_die("Interrupt", 0);
}
static VOID sigtdie(Sigarg)
static void
sigtdie(Sigarg)
{
Use_Sigarg;
sig_die("Killed", 0);
}
#ifdef SIGTRAP
static VOID sigtrdie(Sigarg)
static void
sigtrdie(Sigarg)
{
Use_Sigarg;
sig_die("Trace trap", 1);

View File

@ -22,5 +22,5 @@ typedef Sigret_t (*sig_pf)(Sigarg_t);
#define signal1(a,b) signal(a,(sig_pf)b)
#define Sigarg Int n
#define Sigarg int n
#define Use_Sigarg n = n /* shut up compiler warning */

View File

@ -3,7 +3,7 @@
#include "fio.h"
#include "fmt.h"
y_rsk(Void)
y_rsk(void)
{
if(f__curunit->uend || f__curunit->url <= f__recpos
|| f__curunit->url == 1) return 0;
@ -12,7 +12,7 @@ y_rsk(Void)
} while(++f__recpos < f__curunit->url);
return 0;
}
y_getc(Void)
y_getc(void)
{
int ch;
if(f__curunit->uend) return(-1);
@ -34,7 +34,7 @@ y_getc(Void)
}
static int
y_rev(Void)
y_rev(void)
{
if (f__recpos < f__hiwater)
f__recpos = f__hiwater;
@ -48,13 +48,13 @@ y_rev(Void)
}
static int
y_err(Void)
y_err(void)
{
err(f__elist->cierr, 110, "dfe");
}
static int
y_newrec(Void)
y_newrec(void)
{
y_rev();
f__hiwater = f__cursor = 0;
@ -121,14 +121,14 @@ integer s_wdfe(cilist *a)
fmt_bg();
return(0);
}
integer e_rdfe(Void)
integer e_rdfe(void)
{
f__init = 1;
en_fio();
return(0);
}
integer e_wdfe(Void)
integer e_wdfe(void)
{
f__init = 1;
return en_fio();

View File

@ -43,7 +43,7 @@ integer s_wdue(cilist *a)
err(a->cierr,errno,"write start");
return(0);
}
integer e_rdue(Void)
integer e_rdue(void)
{
f__init = 1;
if(f__curunit->url==1 || f__recpos==f__curunit->url)
@ -53,7 +53,7 @@ integer e_rdue(Void)
err(f__elist->cierr,200,"syserr");
return(0);
}
integer e_wdue(Void)
integer e_wdue(void)
{
f__init = 1;
#ifdef ALWAYS_FLUSH

View File

@ -162,8 +162,8 @@ f__fatal(int n, char *s)
sig_die(" IO", 1);
}
/*initialization routine*/
VOID
f_init(Void)
void
f_init(void)
{ unit *p;
if (f__init & 2)

View File

@ -58,8 +58,6 @@ typedef struct
extern int f__init;
extern cilist *f__elist; /*active external io list*/
extern flag f__reading,f__external,f__sequential,f__formatted;
#undef Void
#define Void void
extern int (*f__getn)(void); /* for formatted input */
extern void (*f__putn)(int); /* for formatted output */
extern void x_putc(int);
@ -78,7 +76,7 @@ extern int isatty(int);
extern int err__fl(int,int,char*);
extern int xrd_SL(void);
extern int f__putbuf(int);
extern int (*f__doend)(Void);
extern int (*f__doend)(void);
extern FILE *f__cf; /*current file*/
extern unit *f__curunit; /*current unit*/
extern unit f__units[];

View File

@ -487,12 +487,12 @@ loop: switch(type_f((p= &f__syl[f__pc])->op))
}
return(0);
}
en_fio(Void)
en_fio(void)
{ ftnint one=1;
return(do_fio(&one,(char *)NULL,(ftnint)0));
}
VOID
fmt_bg(Void)
void
fmt_bg(void)
{
f__workdone=f__cp=f__rp=f__pc=f__cursor=0;
f__cnt[0]=f__ret[0]=0;

View File

@ -6,7 +6,7 @@ char *f__icend;
extern icilist *f__svic;
int f__icnum;
extern int f__hiwater;
z_getc(Void)
z_getc(void)
{
if(f__recpos++ < f__svic->icirlen) {
if(f__icptr >= f__icend) err(f__svic->iciend,(EOF),"endfile");
@ -21,7 +21,7 @@ z_putc(int c)
if (f__icptr < f__icend && f__recpos++ < f__svic->icirlen)
*f__icptr++ = c;
}
z_rnew(Void)
z_rnew(void)
{
f__icptr = f__svic->iciunit + (++f__icnum)*f__svic->icirlen;
f__recpos = 0;
@ -31,7 +31,7 @@ z_rnew(Void)
}
static int
z_endp(Void)
z_endp(void)
{
(*f__donewrec)();
return 0;
@ -62,7 +62,7 @@ c_si(icilist *a)
}
int
iw_rev(Void)
iw_rev(void)
{
if(f__workdone)
z_endp();
@ -83,7 +83,7 @@ integer s_rsfi(icilist *a)
return(0);
}
z_wnew(Void)
z_wnew(void)
{
if (f__recpos < f__hiwater) {
f__icptr += f__hiwater - f__recpos;
@ -109,14 +109,14 @@ integer s_wsfi(icilist *a)
f__doend = z_endp;
return(0);
}
integer e_rsfi(Void)
integer e_rsfi(void)
{ int n;
f__init &= ~2;
n = en_fio();
f__fmtbuf = NULL;
return(n);
}
integer e_wsfi(Void)
integer e_wsfi(void)
{
int n;
f__init &= ~2;

View File

@ -9,7 +9,7 @@ extern int f__icnum;
extern void z_putc(int);
static int
z_wSL(Void)
z_wSL(void)
{
while(f__recpos < f__svic->icirlen)
z_putc(' ');
@ -59,7 +59,7 @@ s_wsli(icilist *a)
return(0);
}
integer e_wsli(Void)
integer e_wsli(void)
{
f__init = 1;
z_wSL();

View File

@ -63,7 +63,7 @@ un_getc(int x, FILE *f__cf)
extern int ungetc(int, FILE*); /* for systems with a buggy stdio.h */
#endif
t_getc(Void)
t_getc(void)
{ int ch;
if(f__curunit->uend) return(EOF);
if((ch=getc(f__cf))!=EOF) return(ch);
@ -71,7 +71,7 @@ t_getc(Void)
f__curunit->uend = l_eof = 1;
return(EOF);
}
integer e_rsle(Void)
integer e_rsle(void)
{
int ch;
f__init = 1;
@ -253,7 +253,7 @@ rd_count(register int ch)
}
static int
l_C(Void)
l_C(void)
{ int ch, nml_save;
double lz;
if(f__lcount>0) return(0);
@ -317,11 +317,11 @@ l_C(Void)
}
static char nmLbuf[256], *nmL_next;
static int (*nmL_getc_save)(Void);
static int (*nmL_getc_save)(void);
static int (*nmL_ungetc_save)(int, FILE*);
static int
nmL_getc(Void)
nmL_getc(void)
{
int rv;
if (rv = *nmL_next++)
@ -386,7 +386,7 @@ Lfinish(int ch, int dot, int *rvp)
}
static int
l_L(Void)
l_L(void)
{
int ch, rv, sawdot;
if(f__lcount>0)
@ -444,7 +444,7 @@ l_L(Void)
#define BUFSIZE 128
static int
l_CHAR(Void)
l_CHAR(void)
{ int ch,size,i;
static char rafail[] = "realloc failure";
char quote,*p;

View File

@ -6,14 +6,14 @@
ftnint L_len;
int f__Aquote;
static VOID
donewrec(Void)
static void
donewrec(void)
{
if (f__recpos)
(*f__donewrec)();
}
static VOID
static void
lwrt_I(longint n)
{
char *p;
@ -28,14 +28,14 @@ lwrt_I(longint n)
while(*p)
PUT(*p++);
}
static VOID
static void
lwrt_L(ftnint n, ftnlen len)
{
if(f__recpos+LLOGW>=L_len)
donewrec();
wrt_L((Uint *)&n,LLOGW, len);
}
static VOID
static void
lwrt_A(char *p, ftnlen len)
{
int a;
@ -150,7 +150,7 @@ l_g(char *buf, double n)
#endif
}
static VOID
static void
l_put(register char *s)
{
register void (*pn)(int) = f__putn;
@ -160,7 +160,7 @@ l_put(register char *s)
(*pn)(c);
}
static VOID
static void
lwrt_F(double n)
{
char buf[LEFBL];
@ -169,7 +169,7 @@ lwrt_F(double n)
donewrec();
l_put(buf);
}
static VOID
static void
lwrt_C(double a, double b)
{
char *ba, *bb, bufa[LEFBL], bufb[LEFBL];

View File

@ -4,7 +4,7 @@
#include "fio.h"
#include "fmt.h"
xrd_SL(Void)
xrd_SL(void)
{ int ch;
if(!f__curunit->uend)
while((ch=getc(f__cf))!='\n')
@ -15,7 +15,7 @@ xrd_SL(Void)
f__cursor=f__recpos=0;
return(1);
}
x_getc(Void)
x_getc(void)
{ int ch;
if(f__curunit->uend) return(EOF);
ch = getc(f__cf);
@ -34,12 +34,12 @@ x_getc(Void)
}
return(-1);
}
x_endp(Void)
x_endp(void)
{
xrd_SL();
return f__curunit->uend == 1 ? EOF : 0;
}
x_rev(Void)
x_rev(void)
{
(void) xrd_SL();
return(0);

View File

@ -10,7 +10,7 @@ extern char *f__icend;
extern icilist *f__svic;
extern int f__icnum, f__recpos;
static int i_getc(Void)
static int i_getc(void)
{
if(f__recpos >= f__svic->icirlen) {
if (f__recpos++ == f__svic->icirlen)
@ -69,7 +69,7 @@ integer s_rsli(icilist *a)
return(0);
}
integer e_rsli(Void)
integer e_rsli(void)
{ f__init = 1; return 0; }
extern int x_rsne(cilist*);

View File

@ -37,7 +37,7 @@
extern flag f__lquit;
extern int f__lcount, nml_read;
extern t_getc(Void);
extern t_getc(void);
#undef abs
#undef min
@ -123,8 +123,8 @@ mk_hashtab(Namelist *nl)
static char Alpha[256], Alphanum[256];
static VOID
nl_init(Void) {
static void
nl_init(void) {
register char *s;
register int c;
@ -227,7 +227,7 @@ getdimen(int *chp, dimen *d, ftnlen delta, ftnlen extent, ftnlen *x1)
}
#ifndef No_Namelist_Questions
static Void
static void
print_ne(cilist *a)
{
flag intext = f__external;

View File

@ -5,7 +5,7 @@
extern char *f__fmtbuf;
integer e_rsfe(Void)
integer e_rsfe(void)
{ int n;
f__init = 1;
n=en_fio();
@ -21,7 +21,7 @@ c_sfe(cilist *a) /* check */
if(!p->ufmt) err(a->cierr,102,"sfe");
return(0);
}
integer e_wsfe(Void)
integer e_wsfe(void)
{
int n;
f__init = 1;

View File

@ -54,7 +54,7 @@ integer s_wsue(cilist *a)
FSEEK(f__cf,(off_t)sizeof(uiolen),SEEK_CUR);
return(0);
}
integer e_wsue(Void)
integer e_wsue(void)
{ off_t loc;
f__init = 1;
fwrite((char *)&f__reclen,sizeof(uiolen),1,f__cf);
@ -68,7 +68,7 @@ integer e_wsue(Void)
FSEEK(f__cf,loc,SEEK_SET);
return(0);
}
integer e_rsue(Void)
integer e_rsue(void)
{
f__init = 1;
FSEEK(f__cf,(off_t)(f__reclen-f__recpos+sizeof(uiolen)),SEEK_CUR);

View File

@ -8,7 +8,7 @@
#include "f2c.h"
#include "fio.h"
VOID
void
g_char(char *a, ftnlen alen, char *b)
{
char *x = a + alen, *y = b + alen;
@ -26,7 +26,7 @@ g_char(char *a, ftnlen alen, char *b)
while(x-- > a);
}
VOID
void
b_char(char *a, char *b, ftnlen blen)
{ int i;
for(i=0;i<blen && *a!=0;i++) *b++= *a++;

View File

@ -7,7 +7,7 @@ extern icilist *f__svic;
extern char *f__icptr;
static int
mv_cur(Void) /* shouldn't use fseek because it insists on calling fflush */
mv_cur(void) /* shouldn't use fseek because it insists on calling fflush */
/* instead we know too much about stdio */
{
int cursor = f__cursor;

View File

@ -6,7 +6,7 @@
extern int f__hiwater;
int
x_wSL(Void)
x_wSL(void)
{
int n = f__putbuf('\n');
f__hiwater = f__recpos = f__cursor = 0;
@ -14,7 +14,7 @@ x_wSL(Void)
}
static int
xw_end(Void)
xw_end(void)
{
int n;
@ -29,7 +29,7 @@ xw_end(Void)
}
static int
xw_rev(Void)
xw_rev(void)
{
int n = 0;
if(f__workdone) {

View File

@ -21,7 +21,7 @@ integer s_wsle(cilist *a)
return(0);
}
integer e_wsle(Void)
integer e_wsle(void)
{
int n;
f__init = 1;

View File

@ -6,8 +6,8 @@
extern int f__Aquote;
static VOID
nl_donewrec(Void)
static void
nl_donewrec(void)
{
(*f__donewrec)();
PUT(' ');
@ -15,7 +15,7 @@ nl_donewrec(Void)
#include <string.h>
VOID
void
x_wsne(cilist *a)
{
Namelist *nl;

View File

@ -23,7 +23,7 @@ static integer c__5 = 5;
/* Local variables */
static char cbuf[24];
extern longint G77_time_0 ();
extern /* Character */ VOID G77_ctime_0 ();
extern /* Character */ void G77_ctime_0 ();
i__1 = G77_time_0 ();
G77_ctime_0 (ch__1, 24L, &i__1);