diff options
author | Barry Warsaw <barry@python.org> | 2004-09-10 03:08:08 (GMT) |
---|---|---|
committer | Barry Warsaw <barry@python.org> | 2004-09-10 03:08:08 (GMT) |
commit | 12827c1fa9e6c87248fa1e5e4341066e41ce4ffb (patch) | |
tree | 2c8f5a24b7b3ff3cd231ad0d5b09e4bde1594f72 /Lib/locale.py | |
parent | 961c2882a920f137543585175db9957bf48223f3 (diff) | |
download | cpython-12827c1fa9e6c87248fa1e5e4341066e41ce4ffb.zip cpython-12827c1fa9e6c87248fa1e5e4341066e41ce4ffb.tar.gz cpython-12827c1fa9e6c87248fa1e5e4341066e41ce4ffb.tar.bz2 |
Many updates to PEP 292 templates. Summary:
- Template no longer inherits from unicode.
- SafeTemplate is removed. Now Templates have both a substitute() and a
safe_substitute() method, so we don't need separate classes. No more
__mod__() operator.
- Adopt Tim Peter's idea for giving Template a metaclass, which makes the
delimiter, the identifier pattern, or the entire pattern easy to override
and document, while retaining efficiency of class-time compilation of the
regexp.
- More informative ValueError messages which will help a user narrow down the
bogus delimiter to the line and column in the original string (helpful for
long triple quoted strings).
Diffstat (limited to 'Lib/locale.py')
0 files changed, 0 insertions, 0 deletions