Re: Commenting C++ code - TIPS

From: John Harrison (john_andronicus_at_hotmail.com)
Date: 05/06/04


Date: 6 May 2004 20:06:02 GMT


"bartek" <spam.will.eat.itself@o2.pl> wrote in message
news:Xns94E1DA57D4976bartekdqwertyuiopo2p@153.19.251.200...
> "John Harrison" <john_andronicus@hotmail.com> wrote in
> news:2fumrpF2ijfgU1@uni-berlin.de:
>
> (...)
>
> > Using an IDE that has syntax colouring you would immediately see which
> > block was commented out. I've never seen an IDE that can colour #if
> > #else #endif blocks though.
>
> FYI, gvim does it. Maybe it's not an IDE in full-blown-sense-of-the-word,
> though, but a bloody useful code editor nonetheless.
>

Does it colour the block depending on whether it will be compiled or not?

#if 0
// one colour
#endif

#if 1
// another colour
#endif

That's what struck me as useful about rajeshb's tip.

john