Block comments? Not working inside a logic block.

Roland Schlenker rol9999 at attglobal.net
Mon May 8 19:44:59 EDT 2000


Ben Park wrote:

> Block commenting does not seem to work inside a logic block. For example
>
> #===================
> if 1:
> '''
> whatever here
> '''
>     print 'I am here'
> #====================
>
> results in error:
>
>     '''
>       ^
> SyntaxError: invalid syntax
>
> In article <391653B7.2F38A7F2 at san.rr.com>,
>   Courageous <jkraska1 at san.rr.com> wrote:
> >
> > Okay, it's not like I'm not looking in my documentation or anything,
> > but if this is available, it's not obvious. How do you express
> > python block comments?
> >
> > C/
> >
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.

#===================
if 1:
    '''
    ^^^   indent after :
whatever here
'''
    print 'I am here'
#====================

Roland Schlenker




More information about the Python-list mailing list