[Python-ideas] Proposal: Tuple of str with w'list of words'

Random832 random832 at fastmail.com
Tue Dec 6 16:01:24 EST 2016


On Sat, Nov 12, 2016, at 13:05, Steven D'Aprano wrote:
> I'm rather luke-warm on this proposal, although I might be convinced to 
> support it if:
> 
> - w'...' unconditionally split on any whitespace (possibly 
>   excluding NBSP);
> 
> - and normal escapes worked.

Is there any particular objection to allowing the backslash-space escape
(and for escapes that mean whitespace characters, such as \t, \x20, to
not split, if you meant to imply that they do)? That would provide the
extra push to this being beneficial over split().

I also have an alternate idea: sl{word1 word2 'string 3' "string 4"}


More information about the Python-ideas mailing list