[Python-checkins] CVS: python/dist/src/Include structmember.h,2.18,2.19

Guido van Rossum gvanrossum@users.sourceforge.net
2001年12月04日 08:23:44 -0800


Update of /cvsroot/python/python/dist/src/Include
In directory usw-pr-cvs1:/tmp/cvs-serv16698/Include
Modified Files:
	structmember.h 
Log Message:
Fix SF bug #486144: Uninitialized __slot__ vrbl is None.
There's now a new structmember code, T_OBJECT_EX, which is used for
all __slot__ variables (except __weakref__, which has special behavior
anyway). This new code raises AttributeError when the variable is
NULL rather than converting NULL to None.
Index: structmember.h
===================================================================
RCS file: /cvsroot/python/python/dist/src/Include/structmember.h,v
retrieving revision 2.18
retrieving revision 2.19
diff -C2 -d -r2.18 -r2.19
*** structmember.h	2001年09月20日 20:46:18	2.18
--- structmember.h	2001年12月04日 16:23:42	2.19
***************
*** 69,72 ****
--- 69,76 ----
 #endif /* macintosh */
 
+ #define T_OBJECT_EX	16	/* Like T_OBJECT, but raises AttributeError
+ 				 when the value is NULL, instead of
+ 				 converting to None. */
+ 
 /* Flags */
 #define READONLY	1

AltStyle によって変換されたページ (->オリジナル) /