summaryrefslogtreecommitdiffstats
path: root/Include/object.h
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1995-01-04 19:06:22 (GMT)
committerGuido van Rossum <guido@python.org>1995-01-04 19:06:22 (GMT)
commit5799b520086129ed8aaadeb3b941b3000a42576a (patch)
treee94f50fbb81224744449a078991c315c18ad2ac9 /Include/object.h
parentaf5b83ec4afa74b3bd1b0750f14fc24bf111c059 (diff)
downloadcpython-5799b520086129ed8aaadeb3b941b3000a42576a.zip
cpython-5799b520086129ed8aaadeb3b941b3000a42576a.tar.gz
cpython-5799b520086129ed8aaadeb3b941b3000a42576a.tar.bz2
Added 1995 copyright.
object.h: made sizes and refcnts signed ints. stringobject.h: make getstrsize() signed int. methodobject.h: add METH_VARARGS and METH_FREENAME flag bit definitions.
Diffstat (limited to 'Include/object.h')
-rw-r--r--Include/object.h14
1 files changed, 7 insertions, 7 deletions
diff --git a/Include/object.h b/Include/object.h
index e419567..433876f 100644
--- a/Include/object.h
+++ b/Include/object.h
@@ -5,8 +5,8 @@ extern "C" {
#endif
/***********************************************************
-Copyright 1991, 1992, 1993, 1994 by Stichting Mathematisch Centrum,
-Amsterdam, The Netherlands.
+Copyright 1991-1995 by Stichting Mathematisch Centrum, Amsterdam,
+The Netherlands.
All Rights Reserved
@@ -99,14 +99,14 @@ whose size is determined when the object is allocated.
#define OB_HEAD_INIT(type) 0, 0, 1, type,
#else
#define OB_HEAD \
- unsigned int ob_refcnt; \
+ int ob_refcnt; \
struct _typeobject *ob_type;
#define OB_HEAD_INIT(type) 1, type,
#endif
#define OB_VARHEAD \
OB_HEAD \
- unsigned int ob_size; /* Number of items in variable part */
+ int ob_size; /* Number of items in variable part */
typedef struct _object {
OB_HEAD
@@ -197,7 +197,7 @@ typedef long (*hashfunc) PROTO((object *));
typedef struct _typeobject {
OB_VARHEAD
char *tp_name; /* For printing */
- unsigned int tp_basicsize, tp_itemsize; /* For allocation */
+ int tp_basicsize, tp_itemsize; /* For allocation */
/* Methods to implement standard operations */
@@ -304,7 +304,7 @@ extern long ref_total;
#endif
#define INCREF(op) (ref_total++, (op)->ob_refcnt++)
#define DECREF(op) \
- if (--ref_total, --(op)->ob_refcnt > 0) \
+ if (--ref_total, --(op)->ob_refcnt != 0) \
; \
else \
DELREF(op)
@@ -316,7 +316,7 @@ extern long ref_total;
#endif
#define INCREF(op) ((op)->ob_refcnt++)
#define DECREF(op) \
- if (--(op)->ob_refcnt > 0) \
+ if (--(op)->ob_refcnt != 0) \
; \
else \
DELREF(op)