Pass character in a subroutine

06-27-2009, 01:35 PM
Hi all
Normally I programming in Fortran 77 and 90 in windows whit Visual Fortran Compaq compiler; but in this days I had to used a macbook whit a Intel Fortran 11 Compiler.

I a problem when I passing a character in a subroutine, because the variable don’t pass;

If my program is:

program pippo
implicit none

call passString('ok')
end program

subroutine passString(st)
implicit none
character*2 :: st
write(*,*) 'string is :', st
end subroutine passString

I don’t have problem when I compile this code, but when I Run or when I debugging, I reciving this message:
“The Debugger has exited due to signal 10 (SIGBUS)”
uff….. I don’t understand. :eek:

06-29-2009, 04:23 AM
… I discover that if I compile in “command line”
with intel fortran don’t have problem and the program is ok.

At this point, I think that the problem is in xCode :(