Languages and Scripting

Calling f90 functions from aCC

news groups
Occasional Advisor

Calling f90 functions from aCC

I'm porting a DOS based code where C++ calls some Fortran functions. In that code, i got a lot of calls with C strings as parameters. The calls are made this way:
char str1[32], str2[32];
int len1=33, len2=33;
function(str1, len1, str2, len2...); // calls a Fortran function
My problem is that it seems that aCC (i use the 3.15 version) and f90 (v2.4) use a different strategy to pass strings as parameters... you should put all the
lengths of the strings at the end of the argument list says the 'Fortran90 programmer's guide'.
So i would have to re-write all my functions as :
function(str1, str2, ... , len1, len2);

In an aCC guide
it is said that i could use the +800 option to allow the length follows immediatly
after the string in the parameter list.
But my f90 compiler doesn't seems to understand that option...

- Is the HP online documentation wrong ?
- Will i have to modify manually all the Fortran calls ?
- Is there any other thing i could do to avoid changing the code ? Any help will be appreciate.

Handy Arry
Occasional Advisor

Re: Calling f90 functions from aCC

+800 is an f77 parameter that is not valid in f90.
See :Fortran 90 Programmer's Guide at .

Looks like the document you refer to is incorrect on this point.

It is an option that does not appear to have been replaced in f90, so I'm not sure what the best course of action would be for you next.