Topic: is interfaceing to fortran being considered as part of the standard?
Author: schuenem@Informatik.TU-Muenchen.DE (Ulf Schuenemann)
Date: 1995/04/07 Raw View
In article <3m0ol1$gq6@fermat.mayo.edu>, stan@chirpa.mayo.edu (Andrew Staniszewski) writes:
[..]
|> since the compiler writer for a particular platform can easily handle the
|> conversions for functions calls (I admit that for character data this may
|> prove inefficient, but there again, I believe so would a user implimentation.)
|> since the fortran compilers are (as far as I have seen) compatible for at least
|> a particular platform, why not provide specifically for
|>
|> extern "FORTRAN" int func(...);
|>
Putting this into the C++standard would require every standard-conforming compiler
to implement this interface. So it will not happen.
It could be a favour for C++ to put it into an "annex", saying:
"If a compiler supports the Fortran intrafec, then it must look like this: ..."
As I've already heard of compilers supporting extern "Fortran", I wonder if
any organisation has standarded this interface (Maybe IEEE).
If such a standard has already been developed by someone AND if it already has
gained a wide acceptance by users and the current implementations of the Fortran
interface, then the C++committee just could addopt this standard as an annex.
(Like the C-libraries are addopted without modifications (?) - AFAIK).
|> just my personal opinion!
just my personal opinion!
Ulf Schuenemann
--------------------------------------------------------------------
Ulf Sch nemann
Fakult t f r Informatik, Technische Universit t M nchen, Germany.
email: schuenem@informatik.tu-muenchen.de
Author: stan@chirpa.mayo.edu (Andrew Staniszewski)
Date: 1995/04/06 Raw View
I know a least a few members of the ANSI/ISO committies read this,
so I want to pitch for adding an additional caveat to the language. interfaceing
to fortran subroutines is something I and many other people end up doing.
Unfortunately, this is a machine dependant problem, some machines adding
underscores after fortran globals, handleing string and character data in differnt
ways etc.
The c++ language already has an interface to a another language, ie:
extern "C" int func(...);
since the compiler writer for a particular platform can easily handle the
conversions for functions calls (I admit that for character data this may
prove inefficient, but there again, I believe so would a user implimentation.)
since the fortran compilers are (as far as I have seen) compatible for at least
a particular platform, why not provide specifically for
extern "FORTRAN" int func(...);
just my personal opinion!
--
------------------------------------------------------------------------------
Andrew Staniszewski
staniszewski@mayo.edu
" ... is everybody else going forwards,
or are we just going backwards ??" MDE
------------------------------------------------------------------------------