Comment Syntax

Doug Gwyn gwyn at smoke.brl.mil
Fri Nov 9 16:01:04 AEST 1990


In article <HAGERMAN.90Nov7193212 at rx7.ece.cmu.edu> hagerman at ece.cmu.edu (John Hagerman) writes:
>Why didn't // ... newline comments make it into ANSI C?

They weren't in the base document, and one style of comment was deemed to
be sufficient.  (Note:  I once added support for this feature to the
Ritchie PDP-11 compiler that I maintained, and when a new non-PDP-11
computer was acquired just after I left, the staff at that company was
tasked with either hacking support for // comments into the new compiler
and indeed, into every future compiler they might have to use, or else
converting all the sources into normal C comment style.  Fortunately I
had left them with a utility for automatically performing such conversion,
based on an FSA.  (It was non-trivial, due to \, ', and " handling.)  Thus,
you know that I must like // comments, but on the other hand I learned a
lesson.)



More information about the Comp.std.c mailing list