[Python-ideas] Idea for new multi-line triple quote literal
nbv4
nbvfour at gmail.com
Mon Jul 1 02:32:07 CEST 2013
The tripple quote string literal is a great feature, but there is one
problem. When you use them, it forces you to break out of you're current
indentation which maks code look ugly. I propose a new way to define a
triple back quote that woks the same way regular triple quotes work, but
instead does some simple parsing of the data within the quotes to preserve
the flow of the code. Due to the brittle and sometimes ambigious nature of
anything 'automatic', this feature is obviously not meant for data where
exact white space is needed. It would be great for docstrings, exception
messages and other type text.
Here is a short example of it's usage:
https://gist.github.com/priestc/5897602
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20130630/e2733a37/attachment.html>
More information about the Python-ideas
mailing list