Peter and all,
On 2005 Apr 12 , at 19.56, Peter W. Draper wrote:
> Norman,
>
> I guess we should test compilers for this behaviour and parameterise
> it.
OK -- you specify the interface and I'll run up the macro.
We could either have a macro STAR_FC_LITERAL_BACKSLASH which adds the
FCFLAGS to have backslashes treated literally; or have
STAR_FC_LITERAL_BACKSLASH(yes|no) to have them treated literally or not
according to whim; or have it so that it simply tests what the compiler
is set to do by default and #defines a suitable flag (probably
FC_LITERAL_BACKSLASH) in config.h for a .F file to switch on.
The first two would require that we assemble the appropriate flags for
all the Fortran compilers we can think of, and is therefore rather
fragile to new compilers appearing; the last is probably a bit more of
a faff to use (but how often do we use it?), but more robust in that it
doesn't have to have wired into it a list of candidate flags.
Which do you fancy?
Norman
--
----------------------------------------------------------------------
Norman Gray : Physics & Astronomy, Glasgow University, UK
http://www.astro.gla.ac.uk/users/norman/ : www.starlink.ac.uk
|