Re: how do you send a fortran character string from GCC to GFortran ?

Liste des GroupesRevenir à cl fortran 
Sujet : Re: how do you send a fortran character string from GCC to GFortran ?
De : lynnmcguire5 (at) *nospam* gmail.com (Lynn McGuire)
Groupes : comp.lang.fortran
Date : 10. Jan 2025, 23:32:27
Autres entêtes
Organisation : A noiseless patient Spider
Message-ID : <vls75t$8o7a$1@dont-email.me>
References : 1 2
User-Agent : Mozilla Thunderbird
On 1/2/2025 4:06 AM, Thomas Koenig wrote:
Lynn McGuire <lynnmcguire5@gmail.com> schrieb:
How do you send a fortran character string from GCC to GFortran ?
>
I cannot get this to link.  I can do the reverse, send a fortran
character string from Gfortran to GCC.
 A full, self-contained example would be helpful for somebody trying to
help (especially since you say "link", which seems weird).
 But take a look at
 https://gcc.gnu.org/onlinedocs/gfortran/Naming-and-argument-passing-conventions.html
 
I do have the additional complication that I do not know the length of
the fortran character string being sent from GCC to Gfortran at compile
time, only run time.  So that is a character*(*) string.
>
I am not using the ISO C binding.
 It is generally a good idea to use ISO C binding in new code, it
is what it was introduced for.
 But you might also find
 https://gcc.gnu.org/onlinedocs/gfortran/Interoperability-Options.html
 of interest.
BTW, I have thousands of calls from my Fortran code to my C code. Adding all of the ISO C binding syntax will take a lot of time.  And breakage of what was working code using the Watcom Fortran and C compilers.
Lynn

Date Sujet#  Auteur
2 Jan 25 * how do you send a fortran character string from GCC to GFortran ?10Lynn McGuire
2 Jan 25 +* Re: how do you send a fortran character string from GCC to GFortran ?3Thomas Koenig
2 Jan 25 i+- Re: how do you send a fortran character string from GCC to GFortran ?1Lynn McGuire
10 Jan 25 i`- Re: how do you send a fortran character string from GCC to GFortran ?1Lynn McGuire
2 Jan 25 +* Re: how do you send a fortran character string from GCC to GFortran ?5Steven G. Kargl
2 Jan 25 i`* Re: how do you send a fortran character string from GCC to GFortran ?4Lynn McGuire
3 Jan 25 i +- Re: how do you send a fortran character string from GCC to GFortran ?1Steven G. Kargl
9 Jan 25 i `* Re: how do you send a fortran character string from GCC to GFortran ?2Thomas Jahns
9 Jan 25 i  `- Re: how do you send a fortran character string from GCC to GFortran ?1Thomas Koenig
3 Jan 25 `- Re: how do you send a fortran character string from GCC to GFortran ?1Lawrence D'Oliveiro

Haut de la page

Les messages affichés proviennent d'usenet.

NewsPortal