Mail Archives: djgpp/1998/02/20/17:31:05
In article <87lnv6wo4s DOT fsf AT hasn DOT dera DOT gov DOT uk>, Ian Miller <itmiller AT dera DOT gov DOT uk>
writes:
>
>The C preprocessor already does this. Of course, it does a bunch of other
>things too (expands macros and so on) but it's probably worth looking at.
>I suspect you can control what it does with command line switches if you
>run it by hand.
>
>Out of interest, why would you want to do this?
If compilation speed is important, minds well remove it from all
header files that don't need it, and keep as *.txt if you need it.
>Does anyone know of a utility to add comments to source files. Now that
>*would* be useful. :)
sure :-)
#include <stdio.h>
char buf[0x1000];
int main()
{
puts("/*Copyright (C) This source is now owned by me.*/");
while (gets(buf)) puts(buf);
return 0;
}
Aloha
- Raw text -