home *** CD-ROM | disk | FTP | other *** search
- Xref: sparky comp.lang.fortran:4259 comp.sys.hp:12748
- Newsgroups: comp.lang.fortran,comp.sys.hp
- Path: sparky!uunet!utcsri!helios.physics.utoronto.ca!alchemy.chem.utoronto.ca!mroussel
- From: mroussel@alchemy.chem.utoronto.ca (Marc Roussel)
- Subject: Weird HP compiler warning
- Message-ID: <1992Nov10.193635.2736@alchemy.chem.utoronto.ca>
- Sender: mroussel@alchemy.chem.utoronto.ca (Marc Roussel)
- Organization: Department of Chemistry, University of Toronto
- Date: Tue, 10 Nov 1992 19:36:35 GMT
- Lines: 34
-
- I usually like my compilers to give me a lot of warnings, even when
- they are most likely useless. In this case however, I have run across
- one warning whose meaning I cannot fathom. Consider the following short
- program:
-
- double precision h,nexth,err,d2fex
- h = 1.d0
- err = 10.d0
- d2fex = 123.d0
- nexth = min(h,sqrt(12.d0*err/d2fex))
- write(*,*)nexth
- END
-
- For this piece of code, the compiler produces the warning
-
- Warning on line 5 of weird.f: Argument has same name as INTRINSIC function
-
- Of course the argument has the same name as an intrinsic! The argument
- IS an intrinsic! Am I going to get this silly warning every time I put
- one intrinsic inside another? My only comfort is that the program
- executes correctly despite a warning which, to me at least, seems to
- suggest that the compiler didn't get it.
- If anyone on HP's compiler team is reading this, I would very much
- like to know what the rationale behind this strange warning is. If
- anyone else can actually think of a reason why such a warning should be
- issued, I would very much like to hear it.
- HP's compiler produces plenty of other warnings which no other sane
- compiler does, but at least I can see some sort of warped logic
- to most of the others I've seen so far. (There's an EXTERNAL warning
- which annoys me, but I think I understand why it's issued.) This one
- baffles me.
-
- Marc R. Roussel
- mroussel@alchemy.chem.utoronto.ca
-