title: Too many characters in a line create "Invalid form of array reference" error?
body: <p>This code:</p>
  
  <pre><code>uhelp(2:100-1,2:100-1) = (1.000000-omega)*u(2:99,2:99)+omega*0.250000*(f(2:99,2:99)+u(2-1:100-1-1,2:100-1)+u(2:100-1,2-1:100-1-1))
  </code></pre>
  
  <p>gives me the following error when compiled with: <code>gfortran -o foo foo.f90</code></p>
  
  <pre><code>)+omega*0.250000*(f(2:99,2:99)+u(2-1:100-1-1,2:100-1)+u(2:100-1,2-1:100-1-1
                                                                         1                                                         
  Error: Invalid form of array reference at (1)
  </code></pre>
  
  <p>I investigated the array indices and after trying a few things found to my surprise that by simply shortening the length of the statement I can get rid of the error. E.g., this works:</p>
  
  <pre><code>uhelp(2:100-1,2:100-1) = u(2:99,2:99)+omega*0.250000*(f(2:99,2:99)+u(2-1:100-1-1,2:100-1)+u(2:100-1,2-1:100-1-1))
  </code></pre>
  
  <p>(Notice that the first term right after the equal sign was removed)</p>
  
  <p>The Fortran code is generated by my own compiler (it parses some toy language to fortran 90 and does some vectorization on the way, if possible. That's why the code looks like it does). I can't easily rewrite the input file so that shorter statements are generated. Is there a certain limit of how many characters the fortran compiler can process per line? If yes, how can I circumvent this problem? I don't know much about fortran, so I might be on the wrong track here.</p>
  
  <p>Fortran version: 
  GNU Fortran (Ubuntu/Linaro 4.7.3-2ubuntu4) 4.7.3</p>
  
  <p>Disclaimer: This problem arose while doing a homework assignment.</p>