<div>
On discussions I've seen, including in this very thread ( <a href="http://mail.python.org/pipermail/python-ideas/2012-June/015544.html">http://mail.python.org/pipermail/python-ideas/2012-June/015544.html</a> ), there are inevitably people that think the multi-line string comment syntax is non-Pythonic, confusing, and/or a bad practice.
 While they can adapt to it, the initial impression is often that it's an overly-clever hack.<br><br>String literals <em>work</em> as comments in other languages, but the idiomatic usage is always the dedicated comment syntax (even if there isn't a multi-line syntax) because people assume that uncommented code is active and significant.  The same goes for other tricks that use dead code as comments, such as the <font face="arial,helvetica,sans-serif">"</font><font face="courier new,monospace">if false:</font><font face="arial,helvetica,sans-serif">" block I've seen suggested as an alternative.  Comments do more than just delimit non-code: they signal developer intent.</font><br>
</div><br><div class="gmail_quote">On Fri, Jun 15, 2012 at 4:51 PM, Guido van Rossum <span dir="ltr"><<a href="mailto:guido@python.org" target="_blank">guido@python.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="im">On Fri, Jun 15, 2012 at 3:47 PM, David Gates <<a href="mailto:gatesda@gmail.com">gatesda@gmail.com</a>> wrote:<br>
> My proposal wasn't for people who hand-code the single-line comment syntax<br>
> but for those that use multi-line string comments.  Since the multi-line<br>
> string hack's BDFL-approved, people will use it and other people will have<br>
> to deal with it.<br>
<br>
</div>What's wrong with it?<br>
<div class="im"><br>
> The best alternative would be official discouragement of multi-line string<br>
> comments.  It's fine if Python doesn't have an officially-sanctioned<br>
> multi-line comment syntax, but if it's going to have one, it should have one<br>
> that makes sense.<br>
<br>
</div>What doesn't make sense about it?<br>
<br>
--Guido<br>
<div class="HOEnZb"><div class="h5"><br>
> On Fri, Jun 15, 2012 at 4:12 PM, Steven D'Aprano <<a href="mailto:steve@pearwood.info">steve@pearwood.info</a>><br>
> wrote:<br>
>><br>
>> David Gates wrote:<br>
>>><br>
>>> Multi-line strings as comments don't nest, don't play well with<br>
>>> docstrings,<br>
>>> and are counter-intuitive when there's special language support for<br>
>>> single-line comments. Python should only have one obvious way to do<br>
>>> things,<br>
>><br>
>><br>
>> That's not what the Zen says. The zen says:<br>
>><br>
>> There should be one-- and preferably only one --obvious way to do it.<br>
>><br>
>> which is a positive statement that there should be an obvious way to solve<br>
>> problems, NOT a negative statement that there shouldn't be non-obvious ways.<br>
>><br>
>>> and Python has two ways to comment, only one of which is obvious. My<br>
>>> suggestion is to add language support for comment blocks, using Python's<br>
>>> existing comment delimiter:<br>
>><br>
>><br>
>> There is already support for nested multi-line comments: the humble #<br>
>> symbol can be nested arbitrarily deep. All you need is a modern editor that<br>
>> understands Python syntax, and with a single command you can comment or<br>
>> uncomment a block:<br>
>><br>
>> # This is a commented line.<br>
>><br>
>> # def fun(a, b, c):<br>
>> #     """Docstrings are fine when commented"""<br>
>> #     pass<br>
>> #     # This is a nested comment.<br>
>> # And no need for an end-delimiter either.<br>
>><br>
>> If your editor is old or too basic, you can do it by hand, which is a<br>
>> pain, but doable.<br>
>><br>
>> Python doesn't need dedicated syntax to make up for the limitations of<br>
>> your editor. Don't complicate the language for the sake of those poor fools<br>
>> stuck using Notepad.<br>
>><br>
>><br>
>><br>
>> --<br>
>> Steven<br>
>> _______________________________________________<br>
>> Python-ideas mailing list<br>
>> <a href="mailto:Python-ideas@python.org">Python-ideas@python.org</a><br>
>> <a href="http://mail.python.org/mailman/listinfo/python-ideas" target="_blank">http://mail.python.org/mailman/listinfo/python-ideas</a><br>
><br>
><br>
><br>
> _______________________________________________<br>
> Python-ideas mailing list<br>
> <a href="mailto:Python-ideas@python.org">Python-ideas@python.org</a><br>
> <a href="http://mail.python.org/mailman/listinfo/python-ideas" target="_blank">http://mail.python.org/mailman/listinfo/python-ideas</a><br>
><br>
<br>
<br>
<br>
</div></div><span class="HOEnZb"><font color="#888888">--<br>
--Guido van Rossum (<a href="http://python.org/~guido" target="_blank">python.org/~guido</a>)<br>
</font></span></blockquote></div><br>