[Python-3000] Adding format to object (original) (raw)
Eric Smith eric+python-dev at trueblade.com
Thu Aug 16 14:08:14 CEST 2007
- Previous message: [Python-3000] Change in sys.stdin.name
- Next message: [Python-3000] Adding __format__ to object
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
As part of implementing PEP 3101, I need to add format to object, to achieve the equivalent of:
class object: def format(self, format_spec): return format(str(self), format_spec)
I've added format to int, unicode, etc., but I can't figure out where or how to add it to object.
Any pointers are appreciated. Something as simple as "look at foo.c" or "grep for baz" would be good enough.
Thanks! Eric.
- Previous message: [Python-3000] Change in sys.stdin.name
- Next message: [Python-3000] Adding __format__ to object
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]