Preprocess settings don't pass to included files

I’m using PGI Visual Fortran 12.5.
I’ve selected to preprocess source files, but this setting don’t get to files, that i include with fortran-style include. Although c-style include works. Example:

commons.inc:

warning Hello

Gives error
Label field of continuation line is not blank
notworks.f95:

include ‘commons.inc’

works.f95:

include “commons.inc”

Hi Senya,

The Fortran “include” statement just copies fortran statements into the body of the source file, it’s not a preprocessor. The preprocessing step occurs before this, hence putting C-type preprocessor statements in the included file wont work since these don’t get preprocessed. If you need C-style statements, you need to use the C-style include.

  • Mat