LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Programming (https://www.linuxquestions.org/questions/programming-9/)
-   -   Fortran - G95 - Wrong Syntax or wrong compiler settings (https://www.linuxquestions.org/questions/programming-9/fortran-g95-wrong-syntax-or-wrong-compiler-settings-629443/)

laucian 03-20-2008 07:53 AM

Fortran - G95 - Wrong Syntax or wrong compiler settings
 
hi everyone,

i have a huge fortran code, which i am trying to get compiled. I didn't write the code, i just have to get it compiled, but i am getting this error message.

Code:

g95  -g -fbounds-check  -c /home/cumhur/doktorArbeit//spraydat.f
In file /home/cumhur/doktorArbeit//spraydat.f:172

      DATA ICHEM/17*0,23,0,10,0,0,0,0,0,0,0,0,0,0,0,0,0,1,6*0/
            1
Error: Not enough values in DATA statement at (1)

what is the meaning of this? is it syntax error or anything else about the compiler?

thanks

colucix 03-21-2008 10:18 AM

It simply states you made an assignement to the variable ICHEM using a lower number of values in respect of the variable declaration. Check in the declaration section, maybe you will find something like
Code:

INTEGER*4 ICHEM(41)
which declares an array of integers with 41 values, but you assigned only 40 in the DATA statement.


All times are GMT -5. The time now is 06:39 PM.