[Python-ideas] Re: Pre PEP: Python Literals (was custom strings before)

2021-06-13 Thread Jim Baker
Supporting JavaScript-style template literals, specifically tagged templates, could be generally useful. If we look at https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_literals#tagged_templates, it's a really simple idea: The tag function is called with the following argu

[Python-ideas] Re: Pre PEP: Python Literals (was custom strings before)

2021-06-13 Thread Chris Angelico
On Mon, Jun 14, 2021 at 8:58 AM Jim Baker wrote: > > * Logging strings which don't have to format their expressions - so similar > to current logging when not using f-strings, but with the easy interface of > f-strings, including desired formatting of expressions in simple logger > scenarios >

[Python-ideas] Re: Pre PEP: Python Literals (was custom strings before)

2021-06-13 Thread Eric V. Smith
On 6/13/2021 7:24 PM, Chris Angelico wrote: On Mon, Jun 14, 2021 at 8:58 AM Jim Baker wrote: * Logging strings which don't have to format their expressions - so similar to current logging when not using f-strings, but with the easy interface of f-strings, including desired formatting of expre