> And a damn good thing too. Heavens! If sanely-indented comments are
> forbidden by the Starlink Fortran style guide, then I would hope that
> assigned GOTO would be, too. Cough.
Where's that? SGP/16 allows either as long as it's done consistently.
I used to indent the comments with the code, but the comments displaced
two characters left so comments didn't line up with the code. The
nesting of the comment headings had relevance. Still that style could
make the thorough comments take lots of lines for well-indented code.
Soon after PROLAT tools appeared I switched to using a fixed indentation
for comments. That was the way Rod was coding too... I used different
underlining of sections of comments, to differentiate main sections from
sub-sections, and have been coding that way ever since, even in Perl and
Java, despite the current fashion of indenting with the code.
The important rule is to *make the comments stand out from the code*, I
feel that the fixed column did that. Indenting can too. However, too
often I find modern code hard to read because the comments are aligned
with the code indentation and/or don't have a blank line before
comments. At least in Fortran the mixed case comment versus uppercase
(usually) code helped differentiate. I've heard it said that the
comment character is the visual clue, but the way my eye examines code
it doesn't pick those up at a glance as easily as the indentation.
Malcolm
|