Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!think.com!zaphod.mps.ohio-state.edu!uwm.edu!convex.csd.uwm.edu!jgd From: jgd@convex.csd.uwm.edu (John G Dobnick) Newsgroups: comp.lang.fortran Subject: A Question of Style Message-ID: <12306@uwm.edu> Date: 21 May 91 02:09:23 GMT Sender: news@uwm.edu Reply-To: jgd@uwm.edu Lines: 61 Originator: jgd@convex.csd.uwm.edu I have recently run into a FORTRAN compiler that exhibits, to my mind, an annoying trait. It complains voiciferously about statement numbers that are defined on statements, but are otherwise unreferenced. In all my years of using FORTRAN compilers, this is the _only_ instance of this behavior I have encountered. (I understand complaints about undefined statement numbers, but this is the opposite case. It's akin to declaring a variable, but never referencing it.) Two things about this behavior annoy me. 1) The warning messages that are generated can (and do) swamp genuine errors in a "sea" of noise messages. 2) These messages cannot be suppressed without also suppressing _real_ warnings. Now, this wouldn't be so bad if all these "Statement number not used" messages were collected in one contiguous block and printed at the end of the other errors/diagnostics, but they are scattered hither and yon _amid_ the more "important" messages. I consider this mis-behavior on the compiler's (and compiler writers') part, and a negative reflection on the "quality of implementation" of the compiler. [Anecdote: I noted this annoying behavior when compiling the "paranoia" program. This program apparently had a long genesis resulting in a veritable multitude of statement numbers, many of which are not referenced in the code. The compiler noted every single bloody one of them! I will note that some of these statement labels are referenced in the commentary text of the code, and in the text messages printed by the program. Thus, the labels are most assuredly _not_ superfluous.] I'm curious about a few things. * Has anyone else encountered FORTRAN compilers with this trait? [Flagging defined but unreferenced statement labels.] * Is this trait good or bad? Desirable or undesirable? * Is the inability to suppress this specific message good or bad? * Is this allowed/forbidden/not-specified by the Standard? (We are speaking X3.9-1978 here. My perusal of the Standard leads me to believe this excessive nattering is not disallowed, but is also not required. However, I'm no standards expert.) * Any general commentary on the above compiler. (Which, other than this peculiarly annoying "habit", is an excellent compiler.) -- John G Dobnick Computing Services Division @ University of Wisconsin - Milwaukee INTERNET: jgd@uwm.edu ATTnet: (414) 229-5727 UUCP: uunet!uwm!jgd "Knowing how things work is the basis for appreciation, and is thus a source of civilized delight." -- William Safire