httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tim Hudson <...@cryptsoft.com>
Subject Re: cvs commit: apachen/src/os/win32 os.h util_win32.c
Date Mon, 17 Nov 1997 09:22:11 GMT
According to Dirk-Willem van Gulik:
> >     I've got a perl script that mostly translates // comments into /* xxx */
> > blocks which I've used to sanitise code from Microsoft weenies that needed
> > to be made cross-platform in a past life. It is ugly but let me know if
> > you want it ...
> perl -pi -e 's%//(.*)$%/*$1 */%g' *.c
> might do ?
    Only for very simple cases ... it is quite normal for a C++ user to
have // inside /* blah blah blah */ blocks that traverse multiple lines
and also to have things like the following when disabling code
    // foo++; /* do something to foo */

    The lack of nesting of /**/ comments makes the simple approach break
on the average bit of "real" code in my experience.

Tim.


Mime
View raw message