[Python-ideas] Fwd: unpacking generalisations for list comprehension
Sjoerd Job Postmus
sjoerdjob at sjoerdjob.com
Wed Oct 26 16:30:05 EDT 2016
On Thu, Oct 27, 2016 at 03:27:07AM +1100, Steven D'Aprano wrote:
> I think that there is zero hope of consistency for * the star operator.
> That horse has bolted. It is already used for:
>
> - ...
> - "zero or more of the previous element" in regular expressions
> - "zero or more of any character" in globbing
> - ...
After having read this multiple times, I still can't really understand
why these two matter to the discussion at hand. It's also used to mark
emphasised text in Markdown, lists in Markdown. You can also use it for
footnotes in plain text. It also has a special meaning in robots.txt
files.
Yes, I agree with you that the meaning of the asterisk symbol is quite
overloaded on the syntax level already. But I think that mentioning
regexes and globbing is a bit of a red herring.
More information about the Python-ideas
mailing list