Community
Participate
Working Groups
Build Identifier: 20100917-0705 forall statements like: forall (i=1:10, j=1:10) A(i,j) = 2.0 are considered syntax errors. If I re-write them as constructs like so: forall (i=1:10, j=1:10) A(i,j) = 2.0 end forall then they are not considered errors. I am importing some code that is valid fortran and compiles with several different compilers. Reproducible: Always Steps to Reproduce: 1. install eclipse 2. open source file with forall statement 3. syntax error 4. close eclipse and continue to work in emacs
This has been reported before (see bug 308196 and also bug 314043 ), and should have been fixed in 6.0 RC2, according to Jeffrey Overbey. I'm currently running 7.0.0.201011121412 and don't get this error anymore.
This appears to be a different problem -- the parser is rejecting forall statements with more than one triplet-spec
This will be fixed in the next 7.0 build. Thanks again for the bug report!
Changed fortran2008.bnf in HEAD: # R750 (list):<ForallTripletSpecList> ::= | <Name> -:T_EQUALS Lb:<Subscript> -:T_COLON Ub:<Subscript> | <Name> -:T_EQUALS Lb:<Subscript> -:T_COLON Ub:<Subscript> -:T_COLON stepExpr:<Expr> | <ForallTripletSpecList> -:T_COMMA <Name> -:T_EQUALS Lb:<Subscript> -:T_COLON Ub:<Subscript> | <ForallTripletSpecList> -:T_COMMA <Name> -:T_EQUALS Lb:<Subscript> -:T_COLON Ub:<Subscript> -:T_COLON stepExpr:<Expr>