Next: , Previous: , Up: Options   [Contents][Index]


4.2.7 ‘-b’: Number blocks (FWEAVE)

Number do and if blocks in woven FORTRAN and RATFOR output. This feature is particularly useful in FORTRAN-77 to help correlate the beginnings and ends of long blocks (but note that appropriate use of literate programming techniques can keep all of one’s blocks short!). Output something like the following is produced, where the comments are inserted automatically by the ‘-b’ option:

do i=1,10 // Block 1
 do j=1,10 // Block 2
  if(i==j) then // Block 3
        call sub1(i)
  else // Block 3
        call sub2(i,j)
  endif // Block 3
 end do // Block 2
end do // Block 1

The precise form of the block comment that is emitted can be changed by redefining the macro \Wblock in fwebmac.sty.