(j3.2006) Intrinsic modules
Van Snyder
Van.Snyder
Fri Nov 20 21:08:13 EST 2009
For the compiler vendors:
Is there a way to tell your compiler to prefer intrinsic modules
(hopefully a list of specific ones) to a nonintrinsic one of the same
name where <module-nature> is not specified in a USE statement
(contradicting 09-007r3:11.2.2p3), even if there's a nonintrinsic one of
the same name in the module search paths? Or is the only way to do it
simply not to have such a one in any directory in the module search
paths?
I have a 1/3-million line program in which we (perhaps unwisely) have
"use IEEE_Arithmetic" in most modules. For platforms that don't offer
the intrinsic module yet, we've written our own. It would be quite
painful to go through the entire program and put either that or "use,
intrinsic :: IEEE_Arithmentc" in place of what we have, controlled by a
preprocessor variable. Perhaps we should have put "use
My_IEEE_Arithmetic" in each place, so we could put "use, intrinsic ::
IEEE_Arithmetic" in that module.
If we were to add to the list in 16.3.1p2:
o is the name of the module or program in which the local identifier
appears
that would also solve the problem (and several others). This wouldn't
cause any trouble (for the standard) because module names only appear in
MODULE, END MODULE, USE, and SUBMODULE statements.
--
Van Snyder | What fraction of Americans believe
Van.Snyder at jpl.nasa.gov | Wrestling is real and NASA is fake?
Any alleged opinions are my own and have not been approved or
disapproved by JPL, CalTech, NASA, the President, or anybody else.
More information about the J3
mailing list