Possible re bug
Barry Scott
barry at barrys-emacs.org
Thu Dec 29 08:17:34 EST 2022
Please please fix you email client so that your replies stay with the
emails you are replying to.
Barry
On 28/12/2022 19:09, Stefan Ram wrote:
> Alexander Richert writes:
> |print(re.findall(".*","pattern"))
> |yields ['pattern',''] which is not what I was expecting.
>
> The asterisk is "greedy", so I agree that it should consume
> /everything/ including all the empty strings at the end.
> To work around this, one can use '^.*' (no smiley intended).
>
>
More information about the Python-list
mailing list