Comments within a line

Dan Bishop danb_83 at yahoo.com
Sat Jul 31 20:39:00 EDT 2004


"Edward Diener" <eldiener at earthlink.net> wrote in message news:<B4OOc.21170$iK.13427 at newsread2.news.atl.earthlink.net>...
> Heike C. Zimmerer wrote:
> > "Edward Diener" <eldiener at earthlink.net> writes:
> >
> >> Has there ever been any discussion of adding comments notation to
> >> Python, such as C++'s /* */, which could occur in the middle of a
> >> line or span multiple lines ? I would like to see it as a more
> >> elegant solution for quickly commenting out code.
> >
> > In C/C++, you wouldn't use /* */ for commenting out code, since it
> > would collide with any comment already there (comments can't be
> > nested).
> 
> That's true but many times it will not, especially if one comments out code
> within a line, or if one is using // liberally also.

I once saw someone write C code that commented out code with /* */
comments, and then decided he needed to temporarily use that code
again, so he commented out the /* and */ with //'s.



More information about the Python-list mailing list