Path: utzoo!mnetor!uunet!husc6!hao!gatech!uflorida!codas!novavax!hcx1!hcx2!bill From: bill@hcx2.SSD.HARRIS.COM Newsgroups: comp.lang.fortran Subject: Re: F8X: MODULE vs. INCLUDE (really Message-ID: <44400018@hcx2> Date: 18 Mar 88 13:48:00 GMT References: <5947@ames.arpa> Lines: 39 Nf-ID: #R:ames.arpa:5947:hcx2:44400018:000:2223 Nf-From: hcx2.SSD.HARRIS.COM!bill Mar 18 08:48:00 1988 > I'm sorry, I could have been a great deal clearer. My point is that the > "dependency" on previously compiled MODULEs is the same as that of > INCLUDE files with the addition of one more check - that the source code > of the module has not been modified since the module was compiled. In > the implementations of modules with which I am familar (HP Modcal, Turbo > Pascal Release 4.0), the compiled form of the module resides in a separate > file from the source, so the regular file system modification dates provide > the information to ensure that the compiled form is not out of date relative > to the source code of the MODULE. With that one additional check, the > dependencies introduced by USE are exactly those of INCLUDE. I agree, Carl, that the "dependency" is the same, but I believe there is danger here in that the compilation system is now leading the user on into a false sense of security. The tendency (particularly with Ada now becoming popular) will be for users to believe that now that the compiler _can_ check the dependency, it will. WRONG!!! First, there is no requirement in the standard that it do any such checking. Second, your proposed method for checking the dependency leaves out a very important safety check: How do you know that two independently-compiled routines that USE the same MODULE were compiled with the same version? This cannot be checked until link-time, because that is the first you have any clue that these two routines are part of one program. That is a much higher burden on the compilation system than simply checking a revision date of a file at compile-time. I don't assert that INCLUDE is any safer, better, or more powerful than MODULE. I only assert that it is such a widespread extension to FORTRAN that it should be standardized in 8x. As for MODULE, I think it is dangerous in its present form (because no checks are required), and I think that requiring the checks would impose too much burden on a compiler for a language that is supposed to compile fast and run fast. Given those opposing requirements, I think MODULE should be deleted. Bill Leonard Member, X3J3 Harris Computer Systems Division Fort Lauderdale, FL bill@ssd.harris.com