This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug fortran/29671] preprocessor statements must start in column 1



------- Comment #1 from burnus at gcc dot gnu dot org  2006-10-31 12:48 -------
The problem is that gfortran calls "cpp" with the -traditional-cpp option.

This causes some more modern constructs not to work and it also is the reason
behind your problem. (cf. PR 28662).

We need to use -traditional-cpp since "some tokens in C are not
tokens in Fortran so you could get the wrong result." (A.P. in the other PR)

The solution is to modify cpp to know fortran tokens (when called with
-lang-fortran).

Note this problem is not limited to gfortran; e.g. the NAG f95 compiler uses
Sun's public-domain fpp (netlib.org/fortran/), which has similar problems.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29671


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]