[Python-Dev] At the interactive port (original) (raw)
Guido van Rossum guido@python.org
Tue, 02 May 2000 07:53:10 -0400
- Previous message: [Python-Dev] At the interactive port
- Next message: [Python-Dev] Comparison inconsistency with ExtensionClass
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
I was planning to submit a patch that adds the built-in routines
sys.display sys.displaytb sys.display sys.displaytb sys.display(obj) would be implemented as 'print repr(obj)' and sys.displaytb(tb, exc) would call the same built-in traceback printer we all know and love.
Sure. Though I would recommend to separate the patch in two parts, because their implementation is totally unrelated.
I assumed that sys.stdin was added to make it easier to restore sys.stdin to its original value. In the same vein, sys.display and sys.displaytb would be saved references to the original sys.display and sys.displaytb.
Good idea.
I hate to contradict Guido, but i'll gently suggest why i like "display" better than "displayhook": "display" is a verb, and i prefer function names to be verbs rather than nouns describing what the functions are (e.g. "read" rather than "reader", etc.)
Good idea. But I hate the "displaytb" name (when I read your message I had no idea what the "tb" stood for until you explained it).
Hm, perhaps we could do showvalue and showtraceback? ("displaytraceback" is a bit long.)
--Guido van Rossum (home page: http://www.python.org/~guido/)
- Previous message: [Python-Dev] At the interactive port
- Next message: [Python-Dev] Comparison inconsistency with ExtensionClass
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]