Steven D'Aprano <st...@pearwood.info> writes:

> On Thu, 28 Nov 2013 13:47:22 +1100, Ben Finney wrote:
> > [A triple-quoted string is] not syntactically a comment, and I don't
> > think pretending triple-quoted strings are comments is good
> > practice. If nothing else, you'll need a special case if you want to
> > enclose something with existing triple-quotes.
>
> The CPython core devs disagree with you. Using bare strings for comments 
> is supported by Python, and the compiler strips them out at
> compile-time:

That's not the same as disagreeing with what I said above. Triple-quoted
strings are not syntactically comments, they're still syntactically
treated as string literals. The implementation detail of them being
stripped out doesn't change that.

Also, “is supported by Python” doesn't mean the developers agree with
the practice.

-- 
 \      “Be careless in your dress if you must, but keep a tidy soul.” |
  `\                              —Mark Twain, _Following the Equator_ |
_o__)                                                                  |
Ben Finney

-- 
https://mail.python.org/mailman/listinfo/python-list

Reply via email to