Non single-line comments?

Wolfgang Grafen wolfgang.grafen at marconi.com
Wed Feb 21 20:45:47 CET 2001


Use """ to comment out blocks:

>>> def ignored_python_code():
...     print "comment out from next line"
...     """
...     { some python code to comment out }
... """
...     print "continue now from here"
... 
>>> ignored_python_code()
comment out from next line
continue now from here


Regards

Wolfgang



"Fernando Rodríguez" wrote:
> 
> Hi!
> 
>         Are there any plans to support non single-line comments (a la /* */ in
> C)? O:-)  I sometimes miss them while debugging...
> 
> //-----------------------------------------------
> //      Fernando Rodriguez Romero
> //
> //      frr at mindless dot com
> //------------------------------------------------



More information about the Python-list mailing list