Feb. 7, 2014
12:11 a.m.
On Fri, Feb 7, 2014 at 10:41 AM, Robert Hölzl <robert.hoelzl@posteo.de> wrote:
How about introducing new string tokens beginning with 'f', which tells the parser to take over that job. In this case one simply had to write:
f"{name} is {value} ({value:X} in hex)"
and the parser would replace this by
"{name} is {value} ({value:X} in hex)".format( **collections.ChainMap(locals(), globals()) )
PHP programmers would love it. Subsequent maintainers would hate it. It's way too magical for my liking. ChrisA