- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I converted a CVF project to IVF in Visual Studio 2008 by opeing the .dsw and then converting the file according to the following link
http://software.intel.com/en-us/articles/migrating-from-compaq-visual-fortran/
When I build the project I get numerous error that surprisngly all are in the comment lines of the header files.
Could you please help me on this?
thanks
Arash
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Problems can arise if the build system is not able to correctly identify whether an included file is in fixed or free Fortran form. Problems can also arise if a fixed-form file is included in a free-form Fortran source file, and vice-versa.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
c earthquake parameters
Error2 error #5082: Syntax error, found IDENTIFIER 'EARTHQUAKE' when expecting one of: ( % : . = =>1
real ruplengthseg(NFSEGMAX), epilon1seg(NFSEGMAX),
Error6 error #5082: Syntax error, found END-OF-STATEMENT when expecting one of: %FILL
are the above infor enough to identify the problem?
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
No. Please display a few lines of the source code that INCLUDEs the lines that you showed, or, if the files are not too long, display their contents or attach them.
I do have a suspicion that the compiler thinks it is compiling free-form source, which would explain its complaining about the 'c' in Col-1, which would have been a comment mark in fixed-form.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
c********1*********2*********3*********4*********5*********6*********7*2
real RUPLEN_FIXED,RUP1,RUP2,RUP3,ZDEDAU,GAMMA0,AAA,
1 ADJUST,ENREL1,ENREL2,ACC2RF1,ACC2RF2,DEFDEPTH,DEFATTN,
1 TIME_BIG,COMMPENALTY,
1 EMINLOSS,ADDSIGMAINTEREVENT,ADDSIGMAINTEREVENT2
real DEDPER
Error Message is:
error #5082: Syntax error, found '**' when expecting one of: ( % : . = =>
c********1*********2*********3*********4*********5*********6*********7*2
-^
error #5082: Syntax error, found END-OF-STATEMENT when expecting one of: %FILL
real RUPLEN_FIXED,RUP1,RUP2,RUP3,ZDEDAU,GAMMA0,AAA,
---------------------------------------------------------^
error #5082: Syntax error, found ',' when expecting one of: ( % : . = =>
1 ADJUST,ENREL1,ENREL2,ACC2RF1,ACC2RF2,DEFDEPTH,DEFATTN,
Thanks
Arash
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
That statement throws some light on your problems. First of all, files included in Fortran are not "header" files. Although included files may have some attributes that they share with C header files, there are substantial differences.
Secondly, Fortran being a compiled language, source files have quite a bit of structure to them, and it does not always make sense to attribute any error to a specific line of source.
Typically, file or file fragment inclusion is performed before the compiler makes a pass at compiling the source. I find it useful to ask myself "what does the compiler see after INCLUDEs have been performed?"
I believe that, in the specific example you presented, you have mixed free-format conventions (beginning statements after zero or more blanks at the beginning of a line, for one) and fixed-format conventions (a 'c' or 'C' in Column-1 signifying a comment). After INCLUDE processing the resulting text input to the compiler must be all free-format or all fixed-format.
Take steps to ensure that the input text to the compiler is consistent in format at the file level. You do not necessarily have to do any format conversions as long as you follow this requirement.
In short, try changing the 'c' in Col-1 to a '!', as required by free-format conventions.

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page