bugfix for fortran code generation