* Copyright (c) 1987 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
static char sccsid
[] = "@(#)fortran.c 5.1 (Berkeley) %G%";
char *lbp
; /* line buffer pointer */
register bool pfcnt
; /* pascal/fortran functions found */
if (!fgets(lbuf
,sizeof(lbuf
),inf
))
if (*lbp
== '%') /* Ratfor escape to fortran */
for (;isspace(*lbp
);++lbp
);
switch (*lbp
| ' ') { /* convert to lower-case */
if (cicmp("complex") || cicmp("character"))
for (;isspace(*lbp
);++lbp
);
for (;isspace(*lbp
);++lbp
);
if (cicmp("program") || cicmp("procedure"))
for (;isspace(*lbp
);++lbp
);
for (cp
= lbp
+ 1;*cp
&& intoken(*cp
);++cp
);
getline(); /* process line for ex(1) */
* do case-independent strcmp
for (len
= 0,bp
= lbp
;*cp
&& (*cp
&~ ' ') == (*bp
++ &~ ' ');
for (;isspace(*lbp
);++lbp
);
for (++lbp
;isspace(*lbp
);++lbp
);
--lbp
; /* force failure */