| 1 | 31 Aug. 1989:
|
|---|
| 2 | 1. A(min(i,j)) now is translated correctly (where A is an array).
|
|---|
| 3 | 2. 7 and 8 character variable names are allowed (but elicit a
|
|---|
| 4 | complaint under -ext).
|
|---|
| 5 | 3. LOGICAL*1 is treated as LOGICAL, with just one error message
|
|---|
| 6 | per LOGICAL*1 statement (rather than one per variable declared
|
|---|
| 7 | in that statement). [Note that LOGICAL*1 is not in Fortran 77.]
|
|---|
| 8 | Like f77, f2c now allows the format in a read or write statement
|
|---|
| 9 | to be an integer array.
|
|---|
| 10 |
|
|---|
| 11 | 5 Sept. 1989:
|
|---|
| 12 | Fixed botch in argument passing of substrings of equivalenced
|
|---|
| 13 | variables.
|
|---|
| 14 |
|
|---|
| 15 | 15 Sept. 1989:
|
|---|
| 16 | Warn about incorrect code generated when a character-valued
|
|---|
| 17 | function is not declared external and is passed as a parameter
|
|---|
| 18 | (in violation of the Fortran 77 standard) before it is invoked.
|
|---|
| 19 | Example:
|
|---|
| 20 |
|
|---|
| 21 | subroutine foo(a,b)
|
|---|
| 22 | character*10 a,b
|
|---|
| 23 | call goo(a,b)
|
|---|
| 24 | b = a(3)
|
|---|
| 25 | end
|
|---|
| 26 |
|
|---|
| 27 | 18 Sept. 1989:
|
|---|
| 28 | Complain about overlapping initializations.
|
|---|
| 29 |
|
|---|
| 30 | 20 Sept. 1989:
|
|---|
| 31 | Warn about names declared EXTERNAL but never referenced;
|
|---|
| 32 | include such names as externs in the generated C (even
|
|---|
| 33 | though most C compilers will discard them).
|
|---|
| 34 |
|
|---|
| 35 | 24 Sept. 1989:
|
|---|
| 36 | New option -w8 to suppress complaint when COMMON or EQUIVALENCE
|
|---|
| 37 | forces word alignment of a double.
|
|---|
| 38 | Under -A (for ANSI C), ensure that floating constants (terminated
|
|---|
| 39 | by 'f') contain either a decimal point or an exponent field.
|
|---|
| 40 | Repair bugs sometimes encountered with CHAR and ICHAR intrinsic
|
|---|
| 41 | functions.
|
|---|
| 42 | Restore f77's optimizations for copying and comparing character
|
|---|
| 43 | strings of length 1.
|
|---|
| 44 | Always assume floating-point valued routines in libF77 return
|
|---|
| 45 | doubles, even under -R.
|
|---|
| 46 | Repair occasional omission of arguments in routines having multiple
|
|---|
| 47 | entry points.
|
|---|
| 48 | Repair bugs in computing offsets of character strings involved
|
|---|
| 49 | in EQUIVALENCE.
|
|---|
| 50 | Don't omit structure qualification when COMMON variables are used
|
|---|
| 51 | as FORMATs or internal files.
|
|---|
| 52 |
|
|---|
| 53 | 2 Oct. 1989:
|
|---|
| 54 | Warn about variables that appear only in data stmts; don't emit them.
|
|---|
| 55 | Fix bugs in character DATA for noncharacter variables
|
|---|
| 56 | involved in EQUIVALENCE.
|
|---|
| 57 | Treat noncharacter variables initialized (at least partly) with
|
|---|
| 58 | character data as though they were equivalenced -- put out a struct
|
|---|
| 59 | and #define the variables. This eliminates the hideous and nonportable
|
|---|
| 60 | numeric values that were used to initialize such variables.
|
|---|
| 61 | Treat IMPLICIT NONE as IMPLICIT UNDEFINED(A-Z) .
|
|---|
| 62 | Quit when given invalid options.
|
|---|
| 63 |
|
|---|
| 64 | 8 Oct. 1989:
|
|---|
| 65 | Modified naming scheme for generated intermediate variables;
|
|---|
| 66 | more are recycled, fewer distinct ones used.
|
|---|
| 67 | New option -W nn specifies nn characters/word for Hollerith
|
|---|
| 68 | data initializing non-character variables.
|
|---|
| 69 | Bug fix: x(i:min(i+10,j)) used to elicit "Can't handle opcode 31 yet".
|
|---|
| 70 | Integer expressions of the form (i+const1) - (i+const2), where
|
|---|
| 71 | i is a scalar integer variable, are now simplified to (const1-const2);
|
|---|
| 72 | this leads to simpler translation of some substring expressions.
|
|---|
| 73 | Initialize uninitialized portions of character string arrays to 0
|
|---|
| 74 | rather than to blanks.
|
|---|
| 75 |
|
|---|
| 76 | 9 Oct. 1989:
|
|---|
| 77 | New option -c to insert comments showing original Fortran source.
|
|---|
| 78 | New option -g to insert line numbers of original Fortran source.
|
|---|
| 79 |
|
|---|
| 80 | 10 Oct. 1989:
|
|---|
| 81 | ! recognized as in-line comment delimiter (a la Fortran 88).
|
|---|
| 82 |
|
|---|
| 83 | 24 Oct. 1989:
|
|---|
| 84 | New options to ease coping with systems that want the structs
|
|---|
| 85 | that result from COMMON blocks to be defined just once:
|
|---|
| 86 | -E causes uninitialized COMMON blocks to be declared Extern;
|
|---|
| 87 | if Extern is undefined, f2c.h #defines it to be extern.
|
|---|
| 88 | -ec causes a separate .c file to be emitted for each
|
|---|
| 89 | uninitialized COMMON block: COMMON /ABC/ yields abc_com.c;
|
|---|
| 90 | thus one can compile *_com.c into a library to ensure
|
|---|
| 91 | precisely one definition.
|
|---|
| 92 | -e1c is similar to -ec, except that everything goes into
|
|---|
| 93 | one file, along with comments that give a sed script for
|
|---|
| 94 | splitting the file into the pieces that -ec would give.
|
|---|
| 95 | This is for use with netlib's "execute f2c" service (for which
|
|---|
| 96 | -ec is coerced into -e1c, and the sed script will put everything
|
|---|
| 97 | but the COMMON definitions into f2c_out.c ).
|
|---|
| 98 |
|
|---|
| 99 | 28 Oct. 1989:
|
|---|
| 100 | Convert "i = i op ..." into "i op= ...;" even when i is a
|
|---|
| 101 | dummy argument.
|
|---|
| 102 |
|
|---|
| 103 | 13 Nov. 1989:
|
|---|
| 104 | Name integer constants (passed as arguments) c__... rather
|
|---|
| 105 | than c_... so
|
|---|
| 106 | common /c/stuff
|
|---|
| 107 | call foo(1)
|
|---|
| 108 | ...
|
|---|
| 109 | is translated correctly.
|
|---|
| 110 |
|
|---|
| 111 | 19 Nov. 1989:
|
|---|
| 112 | Floating-point constants are now kept as strings unless they
|
|---|
| 113 | are involved in constant expressions that get simplified. The
|
|---|
| 114 | floating-point constants kept as strings can have arbitrarily
|
|---|
| 115 | many significant figures and a very large exponent field (as
|
|---|
| 116 | large as long int allows on the machine on which f2c runs).
|
|---|
| 117 | Thus, for example, the body of
|
|---|
| 118 |
|
|---|
| 119 | subroutine zot(x)
|
|---|
| 120 | double precision x(6), pi
|
|---|
| 121 | parameter (pi=3.1415926535897932384626433832795028841972)
|
|---|
| 122 | x(1) = pi
|
|---|
| 123 | x(2) = pi+1
|
|---|
| 124 | x(3) = 9287349823749272.7429874923740978492734D-298374
|
|---|
| 125 | x(4) = .89
|
|---|
| 126 | x(5) = 4.0005
|
|---|
| 127 | x(6) = 10D7
|
|---|
| 128 | end
|
|---|
| 129 |
|
|---|
| 130 | now gets translated into
|
|---|
| 131 |
|
|---|
| 132 | x[1] = 3.1415926535897932384626433832795028841972;
|
|---|
| 133 | x[2] = 4.1415926535897931;
|
|---|
| 134 | x[3] = 9.2873498237492727429874923740978492734e-298359;
|
|---|
| 135 | x[4] = (float).89;
|
|---|
| 136 | x[5] = (float)4.0005;
|
|---|
| 137 | x[6] = 1e8;
|
|---|
| 138 |
|
|---|
| 139 | rather than the former
|
|---|
| 140 |
|
|---|
| 141 | x[1] = 3.1415926535897931;
|
|---|
| 142 | x[2] = 4.1415926535897931;
|
|---|
| 143 | x[3] = 0.;
|
|---|
| 144 | x[4] = (float)0.89000000000000003;
|
|---|
| 145 | x[5] = (float)4.0004999999999997;
|
|---|
| 146 | x[6] = 100000000.;
|
|---|
| 147 |
|
|---|
| 148 | Recognition of f77 machine-constant intrinsics deleted, i.e.,
|
|---|
| 149 | epbase, epprec, epemin, epemax, eptiny, ephuge, epmrsp.
|
|---|
| 150 |
|
|---|
| 151 | 22 Nov. 1989:
|
|---|
| 152 | Workarounds for glitches on some Sun systems...
|
|---|
| 153 | libf77: libF77/makefile modified to point out possible need
|
|---|
| 154 | to compile libF77/main.c with -Donexit=on_exit .
|
|---|
| 155 | libi77: libI77/wref.c (and libI77/README) modified so non-ANSI
|
|---|
| 156 | systems can compile with USE_STRLEN defined, which will cause
|
|---|
| 157 | sprintf(b = buf, "%#.*f", d, x);
|
|---|
| 158 | n = strlen(b) + d1;
|
|---|
| 159 | rather than
|
|---|
| 160 | n = sprintf(b = buf, "%#.*f", d, x) + d1;
|
|---|
| 161 | to be compiled.
|
|---|
| 162 |
|
|---|
| 163 | 26 Nov. 1989:
|
|---|
| 164 | Longer names are now accepted (up to 50 characters); names may
|
|---|
| 165 | contain underscores (in which case they will have two underscores
|
|---|
| 166 | appended, to avoid clashes with library names).
|
|---|
| 167 |
|
|---|
| 168 | 28 Nov. 1989:
|
|---|
| 169 | libi77 updated:
|
|---|
| 170 | 1. Allow 3 (or, on Crays, 4) digit exponents under format Ew.d .
|
|---|
| 171 | 2. Try to get things right on machines where ints have 16 bits.
|
|---|
| 172 |
|
|---|
| 173 | 29 Nov. 1989:
|
|---|
| 174 | Supplied missing semicolon in parameterless subroutines that
|
|---|
| 175 | have multiple entry points (all of them parameterless).
|
|---|
| 176 |
|
|---|
| 177 | 30 Nov. 1989:
|
|---|
| 178 | libf77 and libi77 revised to use types from f2c.h.
|
|---|
| 179 | f2c now types floating-point valued C library routines as "double"
|
|---|
| 180 | rather than "doublereal" (for use with nonstandard C compilers for
|
|---|
| 181 | which "double" is IEEE double extended).
|
|---|
| 182 |
|
|---|
| 183 | 1 Dec. 1989:
|
|---|
| 184 | f2c.h updated to eliminate #defines rendered unnecessary (and,
|
|---|
| 185 | indeed, dangerous) by change of 26 Nov. to long names possibly
|
|---|
| 186 | containing underscores.
|
|---|
| 187 | libi77 further revised: yesterday's change omitted two tweaks to fmt.h
|
|---|
| 188 | (tweaks which only matter if float and real or double and doublereal are
|
|---|
| 189 | different types).
|
|---|
| 190 |
|
|---|
| 191 | 2 Dec. 1989:
|
|---|
| 192 | Better error message (than "bad tag") for NAMELIST, which no longer
|
|---|
| 193 | inhibits C output.
|
|---|
| 194 |
|
|---|
| 195 | 4 Dec. 1989:
|
|---|
| 196 | Allow capital letters in hex constants (f77 extension; e.g.,
|
|---|
| 197 | x'a012BCd', X'A012BCD' and x'a012bcd' are all treated as the integer
|
|---|
| 198 | 167848909).
|
|---|
| 199 | libi77 further revised: lio.c lio.h lread.c wref.c wrtfmt.c tweaked
|
|---|
| 200 | again to allow float and real or double and doublereal to be different.
|
|---|
| 201 |
|
|---|
| 202 | 6 Dec. 1989:
|
|---|
| 203 | Revised f2c.h -- required for the following...
|
|---|
| 204 | Simpler looking translations for abs, min, max, using #defines in
|
|---|
| 205 | revised f2c.h .
|
|---|
| 206 | libi77: more corrections to types; additions for NAMELIST.
|
|---|
| 207 | Corrected casts in some I/O calls.
|
|---|
| 208 | Translation of NAMELIST; libi77 must still be revised. Currently
|
|---|
| 209 | libi77 gives you a run-time error message if you attempt NAMELIST I/O.
|
|---|
| 210 |
|
|---|
| 211 | 7 Dec. 1989:
|
|---|
| 212 | Fixed bug that prevented local integer variables that appear in DATA
|
|---|
| 213 | stmts from being ASSIGNed statement labels.
|
|---|
| 214 | Fillers (for DATA statements initializing EQUIVALENCEd variables and
|
|---|
| 215 | variables in COMMON) typed integer rather than doublereal (for slightly
|
|---|
| 216 | more portability, e.g. to Crays).
|
|---|
| 217 | libi77: missing return values supplied in a few places; some tests
|
|---|
| 218 | reordered for better working on the Cray.
|
|---|
| 219 | libf77: better accuracy for complex divide, complex square root,
|
|---|
| 220 | real mod function (casts to double; double temporaries).
|
|---|
| 221 |
|
|---|
| 222 | 9 Dec. 1989:
|
|---|
| 223 | Fixed bug that caused needless (albeit harmless) empty lines to be
|
|---|
| 224 | inserted in the C output when a comment line contained trailing blanks.
|
|---|
| 225 | Further tweak to type of fillers: allow doublereal fillers if the
|
|---|
| 226 | struct has doublereal data.
|
|---|
| 227 |
|
|---|
| 228 | 11 Dec. 1989:
|
|---|
| 229 | Alteration of rule for producing external (C) names from names that
|
|---|
| 230 | contain underscores. Now the external name is always obtained by
|
|---|
| 231 | appending a pair of underscores.
|
|---|
| 232 |
|
|---|
| 233 | 12 Dec. 1989:
|
|---|
| 234 | C production inhibited after most errors.
|
|---|
| 235 |
|
|---|
| 236 | 15 Dec. 1989:
|
|---|
| 237 | Fixed bug in headers for subroutines having two or more character
|
|---|
| 238 | strings arguments: the length arguments were reversed.
|
|---|
| 239 |
|
|---|
| 240 | 19 Dec. 1989:
|
|---|
| 241 | f2c.h libf77 libi77: adjusted so #undefs in f2c.h should not foil
|
|---|
| 242 | compilation of libF77 and libI77.
|
|---|
| 243 | libf77: getenv_ adjusted to work with unsorted environments.
|
|---|
| 244 | libi77: the iostat= specifier should now work right with internal I/O.
|
|---|
| 245 |
|
|---|
| 246 | 20 Dec. 1989:
|
|---|
| 247 | f2c bugs fixed: In the absence of an err= specifier, the iostat=
|
|---|
| 248 | specifier was generally set wrong. Character strings containing
|
|---|
| 249 | explicit nulls (\0) were truncated at the first null.
|
|---|
| 250 | Unlabeled DO loops recognized; must be terminated by ENDDO.
|
|---|
| 251 | (Don't ask for CYCLE, EXIT, named DO loops, or DO WHILE.)
|
|---|
| 252 |
|
|---|
| 253 | 29 Dec. 1989:
|
|---|
| 254 | Nested unlabeled DO loops now handled properly; new warning for
|
|---|
| 255 | extraneous text at end of FORMAT.
|
|---|
| 256 |
|
|---|
| 257 | 30 Dec. 1989:
|
|---|
| 258 | Fixed bug in translating dble(real(...)), dble(sngl(...)), and
|
|---|
| 259 | dble(float(...)), where ... is either of type double complex or
|
|---|
| 260 | is an expression requiring assignment to intermediate variables (e.g.,
|
|---|
| 261 | dble(real(foo(x+1))), where foo is a function and x is a variable).
|
|---|
| 262 | Regard nonblank label fields on continuation lines as an error.
|
|---|
| 263 |
|
|---|
| 264 | 3 Jan. 1990:
|
|---|
| 265 | New option -C++ yields output that should be understood
|
|---|
| 266 | by C++ compilers.
|
|---|
| 267 |
|
|---|
| 268 | 6 Jan. 1989:
|
|---|
| 269 | -a now excludes variables that appear in a namelist from those
|
|---|
| 270 | that it makes automatic. (As before, it also excludes variables
|
|---|
| 271 | that appear in a common, data, equivalence, or save statement.)
|
|---|
| 272 | The syntactically correct Fortran
|
|---|
| 273 | read(*,i) x
|
|---|
| 274 | end
|
|---|
| 275 | now yields syntactically correct C (even though both the Fortran
|
|---|
| 276 | and C are buggy -- no FORMAT has not been ASSIGNed to i).
|
|---|
| 277 |
|
|---|
| 278 | 7 Jan. 1990:
|
|---|
| 279 | libi77: routines supporting NAMELIST added. Surrounding quotes
|
|---|
| 280 | made optional when no ambiguity arises in a list or namelist READ
|
|---|
| 281 | of a character-string value.
|
|---|
| 282 |
|
|---|
| 283 | 9 Jan. 1990:
|
|---|
| 284 | f2c.src made available.
|
|---|
| 285 |
|
|---|
| 286 | 16 Jan. 1990:
|
|---|
| 287 | New options -P to produce ANSI C or C++ prototypes for procedures
|
|---|
| 288 | defined. Change to -A and -C++: f2c tries to infer prototypes for
|
|---|
| 289 | invoked procedures unless the new -!P option is given. New warning
|
|---|
| 290 | messages for inconsistent calling sequences among procedures within
|
|---|
| 291 | a single file. Most of f2c/src is affected.
|
|---|
| 292 | f2c.h: typedefs for procedure arguments added; netlib's f2c service
|
|---|
| 293 | will insert appropriate typedefs for use with older versions of f2c.h.
|
|---|
| 294 |
|
|---|
| 295 | 17 Jan. 1990:
|
|---|
| 296 | f2c/src: defs.h exec.c format.c proc.c putpcc.c version.c xsum0.out
|
|---|
| 297 | updated. Castargs and protofile made extern in defs.h; exec.c
|
|---|
| 298 | modified so superfluous else clauses are diagnosed; unused variables
|
|---|
| 299 | omitted from declarations in format.c proc.c putpcc.c .
|
|---|
| 300 |
|
|---|
| 301 | 21 Jan. 1990:
|
|---|
| 302 | No C emitted for procedures declared external but not referenced.
|
|---|
| 303 | f2c.h: more new types added for use with -P.
|
|---|
| 304 | New feature: f2c accepts as arguments files ending in .p or .P;
|
|---|
| 305 | such files are assumed to be prototype files, such as produced by
|
|---|
| 306 | the -P option. All prototype files are read before any Fortran files
|
|---|
| 307 | and apply globally to all Fortran files. Suitable prototypes help f2c
|
|---|
| 308 | warn about calling-sequence errors and can tell f2c how to type
|
|---|
| 309 | procedures declared external but not explicitly typed; the latter is
|
|---|
| 310 | mainly of interest for users of the -A and -C++ options. (Prototype
|
|---|
| 311 | arguments are not available to netlib's "execute f2c" service.)
|
|---|
| 312 | New option -it tells f2c to try to infer types of untyped external
|
|---|
| 313 | arguments from their use as parameters to prototyped or previously
|
|---|
| 314 | defined procedures.
|
|---|
| 315 | f2c/src: many minor cleanups; most modules changed. Individual
|
|---|
| 316 | files in f2c/src are now in "bundle" format. The former f2c.1 is
|
|---|
| 317 | now f2c.1t; "f2c.1t from f2c" and "f2c.1t from f2c/src" are now the
|
|---|
| 318 | same, as are "f2c.1 from f2c" and "f2c.1 from f2c/src". People who
|
|---|
| 319 | do not obtain a new copy of "all from f2c/src" should at least add
|
|---|
| 320 | fclose(sortfp);
|
|---|
| 321 | after the call on do_init_data(outfile, sortfp) in format_data.c .
|
|---|
| 322 |
|
|---|
| 323 | 22 Jan. 1990:
|
|---|
| 324 | Cleaner man page wording (thanks to Doug McIlroy).
|
|---|
| 325 | -it now also applies to all untyped EXTERNAL procedures, not just
|
|---|
| 326 | arguments.
|
|---|
| 327 |
|
|---|
| 328 | 23 Jan. 01:34:00 EST 1990:
|
|---|
| 329 | Bug fixes: under -A and -C++, incorrect C was generated for
|
|---|
| 330 | subroutines having multiple entries but no arguments.
|
|---|
| 331 | Under -A -P, subroutines of no arguments were given prototype
|
|---|
| 332 | calling sequence () rather than (void).
|
|---|
| 333 | Character-valued functions elicited erroneous warning messages
|
|---|
| 334 | about inconsistent calling sequences when referenced by another
|
|---|
| 335 | procedure in the same file.
|
|---|
| 336 | f2c.1t: omit first appearance of libF77.a in FILES section;
|
|---|
| 337 | load order of libraries is -lF77 -lI77, not vice versa (bug
|
|---|
| 338 | introduced in yesterday's edits); define .F macro for those whose
|
|---|
| 339 | -man lacks it. (For a while after yesterday's fixes were posted,
|
|---|
| 340 | f2c.1t was out of date. Sorry!)
|
|---|
| 341 |
|
|---|
| 342 | 23 Jan. 9:53:24 EST 1990:
|
|---|
| 343 | Character substring expressions involving function calls having
|
|---|
| 344 | character arguments (including the intrinsic len function) yielded
|
|---|
| 345 | incorrect C.
|
|---|
| 346 | Procedures defined after invocation (in the same file) with
|
|---|
| 347 | conflicting argument types also got an erroneous message about
|
|---|
| 348 | the wrong number of arguments.
|
|---|
| 349 |
|
|---|
| 350 | 24 Jan. 11:44:00 EST 1990:
|
|---|
| 351 | Bug fixes: -p omitted #undefs; COMMON block names containing
|
|---|
| 352 | underscores had their C names incorrectly computed; a COMMON block
|
|---|
| 353 | having the name of a previously defined procedure wreaked havoc;
|
|---|
| 354 | if all arguments were .P files, f2c tried reading the second as a
|
|---|
| 355 | Fortran file.
|
|---|
| 356 | New feature: -P emits comments showing COMMON block lengths, so one
|
|---|
| 357 | can get warnings of incompatible COMMON block lengths by having f2c
|
|---|
| 358 | read .P (or .p) files. Now by running f2c twice, first with -P -!c
|
|---|
| 359 | (or -P!c), then with *.P among the arguments, you can be warned of
|
|---|
| 360 | inconsistent COMMON usage, and COMMON blocks having inconsistent
|
|---|
| 361 | lengths will be given the maximum length. (The latter always did
|
|---|
| 362 | happen within each input file; now -P lets you extend this behavior
|
|---|
| 363 | across files.)
|
|---|
| 364 |
|
|---|
| 365 | 26 Jan. 16:44:00 EST 1990:
|
|---|
| 366 | Option -it made less aggressive: untyped external procedures that
|
|---|
| 367 | are invoked are now typed by the rules of Fortran, rather than by
|
|---|
| 368 | previous use of procedures to which they are passed as arguments
|
|---|
| 369 | before being invoked.
|
|---|
| 370 | Option -P now includes information about references, i.e., called
|
|---|
| 371 | procedures, in the prototype files (in the form of special comments).
|
|---|
| 372 | This allows iterative invocations of f2c to infer more about untyped
|
|---|
| 373 | external names, particularly when multiple Fortran files are involved.
|
|---|
| 374 | As usual, there are some obscure bug fixes:
|
|---|
| 375 | 1. Repair of erroneous warning messages about inconsistent number of
|
|---|
| 376 | arguments that arose when a character dummy parameter was discovered
|
|---|
| 377 | to be a function or when multiple entry points involved character
|
|---|
| 378 | variables appearing in a previous entry point.
|
|---|
| 379 | 2. Repair of memory fault after error msg about "adjustable character
|
|---|
| 380 | function".
|
|---|
| 381 | 3. Under -U, allow MAIN_ as a subroutine name (in the same file as a
|
|---|
| 382 | main program).
|
|---|
| 383 | 4. Change for consistency: a known function invoked as a subroutine,
|
|---|
| 384 | then as a function elicits a warning rather than an error.
|
|---|
| 385 |
|
|---|
| 386 | 26 Jan. 22:32:00 EST 1990:
|
|---|
| 387 | Fixed two bugs that resulted in incorrect C for substrings, within
|
|---|
| 388 | the body of a character-valued function, of the function's name, when
|
|---|
| 389 | those substrings were arguments to another function (even implicitly,
|
|---|
| 390 | as in character-string assignment).
|
|---|
| 391 |
|
|---|
| 392 | 28 Jan. 18:32:00 EST 1990:
|
|---|
| 393 | libf77, libi77: checksum files added; "make check" looks for
|
|---|
| 394 | transmission errors. NAMELIST read modified to allow $ rather than &
|
|---|
| 395 | to precede a namelist name, to allow $ rather than / to terminate
|
|---|
| 396 | input where the name of another variable would otherwise be expected,
|
|---|
| 397 | and to regard all nonprinting ASCII characters <= ' ' as spaces.
|
|---|
| 398 |
|
|---|
| 399 | 29 Jan. 02:11:00 EST 1990:
|
|---|
| 400 | "fc from f2c" added.
|
|---|
| 401 | -it option made the default; -!it turns it off. Type information is
|
|---|
| 402 | now updated in a previously missed case.
|
|---|
| 403 | -P option tweaked again; message about when rerunning f2c may change
|
|---|
| 404 | prototypes or declarations made more accurate.
|
|---|
| 405 | New option -Ps implies -P and returns exit status 4 if rerunning
|
|---|
| 406 | f2c -P with prototype inputs might change prototypes or declarations.
|
|---|
| 407 | Now you can execute a crude script like
|
|---|
| 408 |
|
|---|
| 409 | cat *.f >zap.F
|
|---|
| 410 | rm -f zap.P
|
|---|
| 411 | while :; do
|
|---|
| 412 | f2c -Ps -!c zap.[FP]
|
|---|
| 413 | case $? in 4) ;; *) break;; esac
|
|---|
| 414 | done
|
|---|
| 415 |
|
|---|
| 416 | to get a file zap.P of the best prototypes f2c can determine for *.f .
|
|---|
| 417 |
|
|---|
| 418 | Jan. 29 07:30:21 EST 1990:
|
|---|
| 419 | Forgot to check for error status when setting return code 4 under -Ps;
|
|---|
| 420 | error status (1, 2, 3, or, for caught signal, 126) now takes precedence.
|
|---|
| 421 |
|
|---|
| 422 | Jan 29 14:17:00 EST 1990:
|
|---|
| 423 | Incorrect handling of
|
|---|
| 424 | open(n,'filename')
|
|---|
| 425 | repaired -- now treated as
|
|---|
| 426 | open(n,file='filename')
|
|---|
| 427 | (and, under -ext, given an error message).
|
|---|
| 428 | New optional source file memset.c for people whose systems don't
|
|---|
| 429 | provide memset, memcmp, and memcpy; #include <string.h> in mem.c
|
|---|
| 430 | changed to #include "string.h" so BSD people can create a local
|
|---|
| 431 | string.h that simply says #include <strings.h> .
|
|---|
| 432 |
|
|---|
| 433 | Jan 30 10:34:00 EST 1990:
|
|---|
| 434 | Fix erroneous warning at end of definition of a procedure with
|
|---|
| 435 | character arguments when the procedure had previously been called with
|
|---|
| 436 | a numeric argument instead of a character argument. (There were two
|
|---|
| 437 | warnings, the second one incorrectly complaining of a wrong number of
|
|---|
| 438 | arguments.)
|
|---|
| 439 |
|
|---|
| 440 | Jan 30 16:29:41 EST 1990:
|
|---|
| 441 | Fix case where -P and -Ps erroneously reported another iteration
|
|---|
| 442 | necessary. (Only harm is the extra iteration.)
|
|---|
| 443 |
|
|---|
| 444 | Feb 3 01:40:00 EST 1990:
|
|---|
| 445 | Supply semicolon occasionally omitted under -c .
|
|---|
| 446 | Try to force correct alignment when numeric variables are initialized
|
|---|
| 447 | with character data (a non-standard and non-portable practice). You
|
|---|
| 448 | must use the -W option if your code has such data statements and is
|
|---|
| 449 | meant to run on a machine with other than 4 characters/word; e.g., for
|
|---|
| 450 | code meant to run on a Cray, you would specify -W8 .
|
|---|
| 451 | Allow parentheses around expressions in output lists (in write and
|
|---|
| 452 | print statements).
|
|---|
| 453 | Rename source files so their names are <= 12 characters long
|
|---|
| 454 | (so there's room to append .Z and still have <= 14 characters);
|
|---|
| 455 | renamed files: formatdata.c niceprintf.c niceprintf.h safstrncpy.c .
|
|---|
| 456 | f2c material made available by anonymous ftp from research.att.com
|
|---|
| 457 | (look in dist/f2c ).
|
|---|
| 458 |
|
|---|
| 459 | Feb 3 03:49:00 EST 1990:
|
|---|
| 460 | Repair memory fault that arose from use (in an assignment or
|
|---|
| 461 | call) of a non-argument variable declared CHARACTER*(*).
|
|---|
| 462 |
|
|---|
| 463 | Feb 9 01:35:43 EST 1990:
|
|---|
| 464 | Fix erroneous error msg about bad types in
|
|---|
| 465 | subroutine foo(a,adim)
|
|---|
| 466 | dimension a(adim)
|
|---|
| 467 | integer adim
|
|---|
| 468 | Fix improper passing of character args (and possible memory fault)
|
|---|
| 469 | in the expression part of a computed goto.
|
|---|
| 470 | Fix botched calling sequences in array references involving
|
|---|
| 471 | functions having character args.
|
|---|
| 472 | Fix memory fault caused by invocation of character-valued functions
|
|---|
| 473 | of no arguments.
|
|---|
| 474 | Fix botched calling sequence of a character*1-valued function
|
|---|
| 475 | assigned to a character*1 variable.
|
|---|
| 476 | Fix bug in error msg for inconsistent number of args in prototypes.
|
|---|
| 477 | Allow generation of C output despite inconsistencies in prototypes,
|
|---|
| 478 | but give exit code 8.
|
|---|
| 479 | Simplify include logic (by removing some bogus logic); never
|
|---|
| 480 | prepend "/usr/include/" to file names.
|
|---|
| 481 | Minor cleanups (that should produce no visible change in f2c's
|
|---|
| 482 | behavior) in intr.c parse.h main.c defs.h formatdata.c p1output.c .
|
|---|
| 483 |
|
|---|
| 484 | Feb 10 00:19:38 EST 1990:
|
|---|
| 485 | Insert (integer) casts when floating-point expressions are used
|
|---|
| 486 | as subscripts.
|
|---|
| 487 | Make SAVE stmt (with no variable list) override -a .
|
|---|
| 488 | Minor cleanups: change field to Field in struct Addrblock (for the
|
|---|
| 489 | benefit of buggy C compilers); omit system("/bin/cp ...") in misc.c .
|
|---|
| 490 |
|
|---|
| 491 | Feb 13 00:39:00 EST 1990:
|
|---|
| 492 | Error msg fix in gram.dcl: change "cannot make %s parameter"
|
|---|
| 493 | to "cannot make into parameter".
|
|---|
| 494 |
|
|---|
| 495 | Feb 14 14:02:00 EST 1990:
|
|---|
| 496 | Various cleanups (invisible on systems with 4-byte ints), thanks
|
|---|
| 497 | to Dave Regan: vaxx.c eliminated; %d changed to %ld various places;
|
|---|
| 498 | external names adjusted for the benefit of stupid systems (that ignore
|
|---|
| 499 | case and recognize only 6 significant characters in external names);
|
|---|
| 500 | buffer shortened in xsum.c (e.g. for MS-DOS); fopen modes distinguish
|
|---|
| 501 | text and binary files; several unused functions eliminated; missing
|
|---|
| 502 | arg supplied to an unlikely fatalstr invocation.
|
|---|
| 503 |
|
|---|
| 504 | Thu Feb 15 19:15:53 EST 1990:
|
|---|
| 505 | More cleanups (invisible on systems with 4 byte ints); casts inserted
|
|---|
| 506 | so most complaints from cyntax(1) and lint(1) go away; a few (int)
|
|---|
| 507 | versus (long) casts corrected.
|
|---|
| 508 |
|
|---|
| 509 | Fri Feb 16 19:55:00 EST 1990:
|
|---|
| 510 | Recognize and translate unnamed Fortran 8x do while statements.
|
|---|
| 511 | Fix bug that occasionally caused improper breaking of character
|
|---|
| 512 | strings.
|
|---|
| 513 | New error message for attempts to provide DATA in a type-declaration
|
|---|
| 514 | statement.
|
|---|
| 515 |
|
|---|
| 516 | Sat Feb 17 11:43:00 EST 1990:
|
|---|
| 517 | Fix infinite loop clf -> Fatal -> done -> clf after I/O error.
|
|---|
| 518 | Change "if (addrp->vclass = CLPROC)" to "if (addrp->vclass == CLPROC)"
|
|---|
| 519 | in p1_addr (in p1output.c); this was probably harmless.
|
|---|
| 520 | Move a misplaced } in lex.c (which slowed initkey()).
|
|---|
| 521 | Thanks to Gary Word for pointing these things out.
|
|---|
| 522 |
|
|---|
| 523 | Sun Feb 18 18:07:00 EST 1990:
|
|---|
| 524 | Detect overlapping initializations of arrays and scalar variables
|
|---|
| 525 | in previously missed cases.
|
|---|
| 526 | Treat logical*2 as logical (after issuing a warning).
|
|---|
| 527 | Don't pass string literals to p1_comment().
|
|---|
| 528 | Correct a cast (introduced 16 Feb.) in gram.expr; this matters e.g.
|
|---|
| 529 | on a Cray.
|
|---|
| 530 | Attempt to isolate UNIX-specific things in sysdep.c (a new source
|
|---|
| 531 | file). Unless sysdep.c is compiled with SYSTEM_SORT defined, the
|
|---|
| 532 | intermediate files created for DATA statements are now sorted in-core
|
|---|
| 533 | without invoking system().
|
|---|
| 534 |
|
|---|
| 535 | Tue Feb 20 16:10:35 EST 1990:
|
|---|
| 536 | Move definition of binread and binwrite from init.c to sysdep.c .
|
|---|
| 537 | Recognize Fortran 8x tokens < <= == >= > <> as synonyms for
|
|---|
| 538 | .LT. .LE. .EQ. .GE. .GT. .NE.
|
|---|
| 539 | Minor cleanup in putpcc.c: fully remove simoffset().
|
|---|
| 540 | More discussion of system dependencies added to libI77/README.
|
|---|
| 541 |
|
|---|
| 542 | Tue Feb 20 21:44:07 EST 1990:
|
|---|
| 543 | Minor cleanups for the benefit of EBCDIC machines -- try to remove
|
|---|
| 544 | the assumption that 'a' through 'z' are contiguous. (Thanks again to
|
|---|
| 545 | Gary Word.) Also, change log2 to log_2 (shouldn't be necessary).
|
|---|
| 546 |
|
|---|
| 547 | Wed Feb 21 06:24:56 EST 1990:
|
|---|
| 548 | Fix botch in init.c introduced in previous change; only matters
|
|---|
| 549 | to non-ASCII machines.
|
|---|
| 550 |
|
|---|
| 551 | Thu Feb 22 17:29:12 EST 1990:
|
|---|
| 552 | Allow several entry points to mention the same array. Protect
|
|---|
| 553 | parameter adjustments with if's (for the case that an array is not
|
|---|
| 554 | an argument to all entrypoints).
|
|---|
| 555 | Under -u, allow
|
|---|
| 556 | subroutine foo(x,n)
|
|---|
| 557 | real x(n)
|
|---|
| 558 | integer n
|
|---|
| 559 | Compute intermediate variables used to evaluate dimension expressions
|
|---|
| 560 | at the right time. Example previously mistranslated:
|
|---|
| 561 | subroutine foo(x,k,m,n)
|
|---|
| 562 | real x(min(k,m,n))
|
|---|
| 563 | ...
|
|---|
| 564 | write(*,*) x
|
|---|
| 565 | Detect duplicate arguments. (The error msg points to the first
|
|---|
| 566 | executable stmt -- not wonderful, but not worth fixing.)
|
|---|
| 567 | Minor cleanup of min/max computation (sometimes slightly simpler).
|
|---|
| 568 |
|
|---|
| 569 | Sun Feb 25 09:39:01 EST 1990:
|
|---|
| 570 | Minor tweak to multiple entry points: protect parameter adjustments
|
|---|
| 571 | with if's only for (array) args that do not appear in all entry points.
|
|---|
| 572 | Minor tweaks to format.c and io.c (invisible unless your compiler
|
|---|
| 573 | complained at the duplicate #defines of IOSUNIT and IOSFMT or at
|
|---|
| 574 | comparisons of p1gets(...) with NULL).
|
|---|
| 575 |
|
|---|
| 576 | Sun Feb 25 18:40:10 EST 1990:
|
|---|
| 577 | Fix bug introduced Feb. 22: if a subprogram contained DATA and the
|
|---|
| 578 | first executable statement was labeled, then the label got lost.
|
|---|
| 579 | (Just change INEXEC to INDATA in p1output.c; it occurs just once.)
|
|---|
| 580 |
|
|---|
| 581 | Mon Feb 26 17:45:10 EST 1990:
|
|---|
| 582 | Fix bug in handling of " and ' in comments.
|
|---|
| 583 |
|
|---|
| 584 | Wed Mar 28 01:43:06 EST 1990:
|
|---|
| 585 | libI77:
|
|---|
| 586 | 1. Repair nasty I/O bug: opening two files and closing the first
|
|---|
| 587 | (after possibly reading or writing it), then writing the second caused
|
|---|
| 588 | the last buffer of the second to be lost.
|
|---|
| 589 | 2. Formatted reads of logical values treated all letters other than
|
|---|
| 590 | t or T as f (false).
|
|---|
| 591 | libI77 files changed: err.c rdfmt.c Version.c
|
|---|
| 592 | (Request "libi77 from f2c" -- you can't get these files individually.)
|
|---|
| 593 |
|
|---|
| 594 | f2c itself:
|
|---|
| 595 | Repair nasty bug in translation of
|
|---|
| 596 | ELSE IF (condition involving complicated abs, min, or max)
|
|---|
| 597 | -- auxiliary statements were emitted at the wrong place.
|
|---|
| 598 | Supply semicolon previously omitted from the translation of a label
|
|---|
| 599 | (of a CONTINUE) immediately preceding an ELSE IF or an ELSE. This
|
|---|
| 600 | bug made f2c produce invalid C.
|
|---|
| 601 | Correct a memory fault that occurred (on some machines) when the
|
|---|
| 602 | error message "adjustable dimension on non-argument" should be given.
|
|---|
| 603 | Minor tweaks to remove some harmless warnings by overly chatty C
|
|---|
| 604 | compilers.
|
|---|
| 605 | Argument arays having constant dimensions but a variable lower bound
|
|---|
| 606 | (e.g., x(n+1:n+3)) had a * omitted from scalar arguments involved in
|
|---|
| 607 | the array offset computation.
|
|---|
| 608 |
|
|---|
| 609 | Wed Mar 28 18:47:59 EST 1990:
|
|---|
| 610 | libf77: add exit(0) to end of main [return(0) encounters a Cray bug]
|
|---|
| 611 |
|
|---|
| 612 | Sun Apr 1 16:20:58 EDT 1990:
|
|---|
| 613 | Avoid dereferencing null when processing equivalences after an error.
|
|---|
| 614 |
|
|---|
| 615 | Fri Apr 6 08:29:49 EDT 1990:
|
|---|
| 616 | Calls involving alternate return specifiers omitted processing
|
|---|
| 617 | needed for things like min, max, abs, and // (concatenation).
|
|---|
| 618 | INTEGER*2 PARAMETERs were treated as INTEGER*4.
|
|---|
| 619 | Convert some O(n^2) parsing to O(n).
|
|---|
| 620 |
|
|---|
| 621 | Tue Apr 10 20:07:02 EDT 1990:
|
|---|
| 622 | When inconsistent calling sequences involve differing numbers of
|
|---|
| 623 | arguments, report the first differing argument rather than the numbers
|
|---|
| 624 | of arguments.
|
|---|
| 625 | Fix bug under -a: formatted I/O in which either the unit or the
|
|---|
| 626 | format was a local character variable sometimes resulted in invalid C
|
|---|
| 627 | (a static struct initialized with an automatic component).
|
|---|
| 628 | Improve error message for invalid flag after elided -.
|
|---|
| 629 | Complain when literal table overflows, rather than infinitely
|
|---|
| 630 | looping. (The complaint mentions the new and otherwise undocumented
|
|---|
| 631 | -NL option for specifying a larger literal table.)
|
|---|
|
|---|