[Python-ideas] What about regexp string litterals : re".*" ?

2017-03-27 Thread Simon D.
Hello, After some french discussions about this idea, I subscribed here to suggest adding a new string litteral, for regexp, inspired by other types like : u"", r"", b"", br"", f""… The regexp string litteral could be represented by : re"" It would ease the use of regexps in Python, allowing to

Re: [Python-ideas] What about regexp string litterals : re".*" ?

2017-03-28 Thread Simon D.
* Serhiy Storchaka [2017-03-27 18:39:19 +0300]: > There are several regular expression libraries for Python. One of them is > included in the stdlib, but this is not the first regular expression library > in the stdlib and may be not the last. Particular project can choose using > an alternative r

Re: [Python-ideas] What about regexp string litterals : m".*" ?

2017-03-28 Thread Simon D.
* Chris Angelico [2017-03-28 16:37:16 +1100]: > But I think a better solution will be for regex literals to be > syntax-highlighted differently. If they're a truly-supported syntactic > feature, they can be made visually different in your editor, making > the distinction blatantly obvious. > > Th

Re: [Python-ideas] What about regexp string litterals : m".*" ?

2017-03-29 Thread Simon D.
* Simon D. [2017-03-28 09:56:05 +0200]: > The str integrated one also, but maybe confusing, which regexp lib is > used ? (must be the default one). > Ok, this was a mistake, based on JavaScript memories… There is no regexp aware functions around str, but some hint to go find your hap