summaryrefslogtreecommitdiffstats
path: root/Include/object.h
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1993-11-05 10:22:19 (GMT)
committerGuido van Rossum <guido@python.org>1993-11-05 10:22:19 (GMT)
commitc60041175547df61e67ff167bd5ad18f7967795d (patch)
treed22af13adf57d915922d4806b79213ad326603ef /Include/object.h
parent2e8f8a398e135ce4ec235c33eb64c29e6b6114ea (diff)
downloadcpython-c60041175547df61e67ff167bd5ad18f7967795d.zip
cpython-c60041175547df61e67ff167bd5ad18f7967795d.tar.gz
cpython-c60041175547df61e67ff167bd5ad18f7967795d.tar.bz2
* mpzmodule.c: removed redundant mpz_print function.
* object.[ch], bltinmodule.c, fileobject.c: changed str() to call strobject() which calls an object's __str__ method if it has one. strobject() is also called by writeobject() when PRINT_RAW is passed. * ceval.c: rationalize code for PRINT_ITEM (no change in function!) * funcobject.c, codeobject.c: added compare and hash functionality. Functions with identical code objects and the same global dictionary are equal. Code objects are equal when their code, constants list and names list are identical (i.e. the filename and code name don't count). (hash doesn't work yet since the constants are in a list and lists can't be hashed -- suppose this should really be done with a tuple now we have resizetuple!)
Diffstat (limited to 'Include/object.h')
-rw-r--r--Include/object.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/Include/object.h b/Include/object.h
index ab270f8..24989bf 100644
--- a/Include/object.h
+++ b/Include/object.h
@@ -214,6 +214,7 @@ extern typeobject Typetype; /* The type of type objects */
/* Generic operations on objects */
extern int printobject PROTO((object *, FILE *, int));
extern object * reprobject PROTO((object *));
+extern object * strobject PROTO((object *));
extern int cmpobject PROTO((object *, object *));
extern object *getattr PROTO((object *, char *));
extern int hasattr PROTO((object *, char *));