template strings for matching?
skip at pobox.com
skip at pobox.com
Thu Oct 9 09:05:02 EDT 2008
Tino> Yeah, its a bit hard to spot:
Tino> http://docs.python.org/library/stdtypes.html#string-formatting-operations
That shows how to use the template formatting as it currently exists. To my
knowledge there is no support for the inverse operation, which is what Joe
asked about. Given a string and a format string assign the elements of the
string which correspond to the template elements to key/value pairs in a
dictionary.
Skip
More information about the Python-list
mailing list