📄 changes
字号:
31 Aug. 1989: 1. A(min(i,j)) now is translated correctly (where A is an array). 2. 7 and 8 character variable names are allowed (but elicit a complaint under -ext). 3. LOGICAL*1 is treated as LOGICAL, with just one error message per LOGICAL*1 statement (rather than one per variable declared in that statement). [Note that LOGICAL*1 is not in Fortran 77.] Like f77, f2c now allows the format in a read or write statement to be an integer array.5 Sept. 1989: Fixed botch in argument passing of substrings of equivalencedvariables.15 Sept. 1989: Warn about incorrect code generated when a character-valuedfunction is not declared external and is passed as a parameter(in violation of the Fortran 77 standard) before it is invoked.Example: subroutine foo(a,b) character*10 a,b call goo(a,b) b = a(3) end18 Sept. 1989: Complain about overlapping initializations.20 Sept. 1989: Warn about names declared EXTERNAL but never referenced;include such names as externs in the generated C (eventhough most C compilers will discard them).24 Sept. 1989: New option -w8 to suppress complaint when COMMON or EQUIVALENCEforces word alignment of a double. Under -A (for ANSI C), ensure that floating constants (terminatedby 'f') contain either a decimal point or an exponent field. Repair bugs sometimes encountered with CHAR and ICHAR intrinsicfunctions. Restore f77's optimizations for copying and comparing characterstrings of length 1. Always assume floating-point valued routines in libF77 returndoubles, even under -R. Repair occasional omission of arguments in routines having multipleentry points. Repair bugs in computing offsets of character strings involvedin EQUIVALENCE. Don't omit structure qualification when COMMON variables are usedas FORMATs or internal files.2 Oct. 1989: Warn about variables that appear only in data stmts; don't emit them. Fix bugs in character DATA for noncharacter variablesinvolved in EQUIVALENCE. Treat noncharacter variables initialized (at least partly) withcharacter data as though they were equivalenced -- put out a structand #define the variables. This eliminates the hideous and nonportablenumeric values that were used to initialize such variables. Treat IMPLICIT NONE as IMPLICIT UNDEFINED(A-Z) . Quit when given invalid options.8 Oct. 1989: Modified naming scheme for generated intermediate variables;more are recycled, fewer distinct ones used. New option -W nn specifies nn characters/word for Hollerithdata initializing non-character variables. Bug fix: x(i:min(i+10,j)) used to elicit "Can't handle opcode 31 yet". Integer expressions of the form (i+const1) - (i+const2), wherei is a scalar integer variable, are now simplified to (const1-const2);this leads to simpler translation of some substring expressions. Initialize uninitialized portions of character string arrays to 0rather than to blanks.9 Oct. 1989: New option -c to insert comments showing original Fortran source. New option -g to insert line numbers of original Fortran source.10 Oct. 1989: ! recognized as in-line comment delimiter (a la Fortran 88).24 Oct. 1989: New options to ease coping with systems that want the structsthat result from COMMON blocks to be defined just once: -E causes uninitialized COMMON blocks to be declared Extern;if Extern is undefined, f2c.h #defines it to be extern. -ec causes a separate .c file to be emitted for eachuninitialized COMMON block: COMMON /ABC/ yields abc_com.c;thus one can compile *_com.c into a library to ensureprecisely one definition. -e1c is similar to -ec, except that everything goes intoone file, along with comments that give a sed script forsplitting the file into the pieces that -ec would give.This is for use with netlib's "execute f2c" service (for which-ec is coerced into -e1c, and the sed script will put everythingbut the COMMON definitions into f2c_out.c ).28 Oct. 1989: Convert "i = i op ..." into "i op= ...;" even when i is adummy argument.13 Nov. 1989: Name integer constants (passed as arguments) c__... ratherthan c_... so common /c/stuff call foo(1) ...is translated correctly.19 Nov. 1989: Floating-point constants are now kept as strings unless theyare involved in constant expressions that get simplified. Thefloating-point constants kept as strings can have arbitrarilymany significant figures and a very large exponent field (aslarge as long int allows on the machine on which f2c runs).Thus, for example, the body of subroutine zot(x) double precision x(6), pi parameter (pi=3.1415926535897932384626433832795028841972) x(1) = pi x(2) = pi+1 x(3) = 9287349823749272.7429874923740978492734D-298374 x(4) = .89 x(5) = 4.0005 x(6) = 10D7 endnow gets translated into x[1] = 3.1415926535897932384626433832795028841972; x[2] = 4.1415926535897931; x[3] = 9.2873498237492727429874923740978492734e-298359; x[4] = (float).89; x[5] = (float)4.0005; x[6] = 1e8;rather than the former x[1] = 3.1415926535897931; x[2] = 4.1415926535897931; x[3] = 0.; x[4] = (float)0.89000000000000003; x[5] = (float)4.0004999999999997; x[6] = 100000000.; Recognition of f77 machine-constant intrinsics deleted, i.e.,epbase, epprec, epemin, epemax, eptiny, ephuge, epmrsp.22 Nov. 1989: Workarounds for glitches on some Sun systems... libf77: libF77/makefile modified to point out possible needto compile libF77/main.c with -Donexit=on_exit . libi77: libI77/wref.c (and libI77/README) modified so non-ANSIsystems can compile with USE_STRLEN defined, which will cause sprintf(b = buf, "%#.*f", d, x); n = strlen(b) + d1;rather than n = sprintf(b = buf, "%#.*f", d, x) + d1;to be compiled.26 Nov. 1989: Longer names are now accepted (up to 50 characters); names maycontain underscores (in which case they will have two underscoresappended, to avoid clashes with library names).28 Nov. 1989: libi77 updated: 1. Allow 3 (or, on Crays, 4) digit exponents under format Ew.d . 2. Try to get things right on machines where ints have 16 bits.29 Nov. 1989: Supplied missing semicolon in parameterless subroutines thathave multiple entry points (all of them parameterless).30 Nov. 1989: libf77 and libi77 revised to use types from f2c.h. f2c now types floating-point valued C library routines as "double"rather than "doublereal" (for use with nonstandard C compilers forwhich "double" is IEEE double extended).1 Dec. 1989: f2c.h updated to eliminate #defines rendered unnecessary (and,indeed, dangerous) by change of 26 Nov. to long names possiblycontaining underscores. libi77 further revised: yesterday's change omitted two tweaks to fmt.h(tweaks which only matter if float and real or double and doublereal aredifferent types).2 Dec. 1989: Better error message (than "bad tag") for NAMELIST, which no longerinhibits C output.4 Dec. 1989: Allow capital letters in hex constants (f77 extension; e.g.,x'a012BCd', X'A012BCD' and x'a012bcd' are all treated as the integer167848909). libi77 further revised: lio.c lio.h lread.c wref.c wrtfmt.c tweakedagain to allow float and real or double and doublereal to be different.6 Dec. 1989: Revised f2c.h -- required for the following... Simpler looking translations for abs, min, max, using #defines inrevised f2c.h . libi77: more corrections to types; additions for NAMELIST. Corrected casts in some I/O calls. Translation of NAMELIST; libi77 must still be revised. Currentlylibi77 gives you a run-time error message if you attempt NAMELIST I/O.7 Dec. 1989: Fixed bug that prevented local integer variables that appear in DATAstmts from being ASSIGNed statement labels. Fillers (for DATA statements initializing EQUIVALENCEd variables andvariables in COMMON) typed integer rather than doublereal (for slightlymore portability, e.g. to Crays). libi77: missing return values supplied in a few places; some testsreordered for better working on the Cray. libf77: better accuracy for complex divide, complex square root,real mod function (casts to double; double temporaries).9 Dec. 1989: Fixed bug that caused needless (albeit harmless) empty lines to beinserted in the C output when a comment line contained trailing blanks. Further tweak to type of fillers: allow doublereal fillers if thestruct has doublereal data.11 Dec. 1989: Alteration of rule for producing external (C) names from names thatcontain underscores. Now the external name is always obtained byappending a pair of underscores.12 Dec. 1989: C production inhibited after most errors.15 Dec. 1989: Fixed bug in headers for subroutines having two or more characterstrings arguments: the length arguments were reversed.19 Dec. 1989: f2c.h libf77 libi77: adjusted so #undefs in f2c.h should not foilcompilation of libF77 and libI77. libf77: getenv_ adjusted to work with unsorted environments. libi77: the iostat= specifier should now work right with internal I/O.20 Dec. 1989: f2c bugs fixed: In the absence of an err= specifier, the iostat=specifier was generally set wrong. Character strings containingexplicit nulls (\0) were truncated at the first null. Unlabeled DO loops recognized; must be terminated by ENDDO.(Don't ask for CYCLE, EXIT, named DO loops, or DO WHILE.)29 Dec. 1989: Nested unlabeled DO loops now handled properly; new warning forextraneous text at end of FORMAT.30 Dec. 1989: Fixed bug in translating dble(real(...)), dble(sngl(...)), anddble(float(...)), where ... is either of type double complex oris an expression requiring assignment to intermediate variables (e.g.,dble(real(foo(x+1))), where foo is a function and x is a variable).Regard nonblank label fields on continuation lines as an error.3 Jan. 1990: New option -C++ yields output that should be understoodby C++ compilers.6 Jan. 1989: -a now excludes variables that appear in a namelist from thosethat it makes automatic. (As before, it also excludes variablesthat appear in a common, data, equivalence, or save statement.) The syntactically correct Fortran read(*,i) x endnow yields syntactically correct C (even though both the Fortranand C are buggy -- no FORMAT has not been ASSIGNed to i).7 Jan. 1990: libi77: routines supporting NAMELIST added. Surrounding quotesmade optional when no ambiguity arises in a list or namelist READof a character-string value.9 Jan. 1990: f2c.src made available.16 Jan. 1990: New options -P to produce ANSI C or C++ prototypes for proceduresdefined. Change to -A and -C++: f2c tries to infer prototypes forinvoked procedures unless the new -!P option is given. New warningmessages for inconsistent calling sequences among procedures withina single file. Most of f2c/src is affected. f2c.h: typedefs for procedure arguments added; netlib's f2c servicewill insert appropriate typedefs for use with older versions of f2c.h.17 Jan. 1990: f2c/src: defs.h exec.c format.c proc.c putpcc.c version.c xsum0.outupdated. Castargs and protofile made extern in defs.h; exec.cmodified so superfluous else clauses are diagnosed; unused variablesomitted from declarations in format.c proc.c putpcc.c .21 Jan. 1990: No C emitted for procedures declared external but not referenced. f2c.h: more new types added for use with -P. New feature: f2c accepts as arguments files ending in .p or .P;such files are assumed to be prototype files, such as produced bythe -P option. All prototype files are read before any Fortran filesand apply globally to all Fortran files. Suitable prototypes help f2cwarn about calling-sequence errors and can tell f2c how to typeprocedures declared external but not explicitly typed; the latter ismainly of interest for users of the -A and -C++ options. (Prototypearguments are not available to netlib's "execute f2c" service.) New option -it tells f2c to try to infer types of untyped externalarguments from their use as parameters to prototyped or previouslydefined procedures. f2c/src: many minor cleanups; most modules changed. Individualfiles in f2c/src are now in "bundle" format. The former f2c.1 isnow f2c.1t; "f2c.1t from f2c" and "f2c.1t from f2c/src" are now thesame, as are "f2c.1 from f2c" and "f2c.1 from f2c/src". People whodo not obtain a new copy of "all from f2c/src" should at least add fclose(sortfp);after the call on do_init_data(outfile, sortfp) in format_data.c .22 Jan. 1990: Cleaner man page wording (thanks to Doug McIlroy). -it now also applies to all untyped EXTERNAL procedures, not justarguments.23 Jan. 01:34:00 EST 1990:
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -