Mercurial > cpython-lru_cache-weakref
annotate Include/allobjects.h @ 4566:6403c94de50d legacy-trunk
Added safeguard against failure in __del__.
| author | Guido van Rossum <guido@python.org> |
|---|---|
| date | Wed, 27 Nov 1996 19:39:58 +0000 |
| parents | 65d2d8e67da3 |
| children | 2bb0bda1585c |
| rev | line source |
|---|---|
|
1329
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1288
diff
changeset
|
1 #ifndef Py_ALLOBJECTS_H |
|
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1288
diff
changeset
|
2 #define Py_ALLOBJECTS_H |
|
3074
971e5ca18bd1
removed redundant C++ hack
Guido van Rossum <guido@python.org>
parents:
2839
diff
changeset
|
3 /* Since this is a "meta-include" file, no #ifdef __cplusplus / extern "C" { */ |
|
1329
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1288
diff
changeset
|
4 |
| 145 | 5 /*********************************************************** |
| 2058 | 6 Copyright 1991-1995 by Stichting Mathematisch Centrum, Amsterdam, |
| 7 The Netherlands. | |
| 145 | 8 |
| 9 All Rights Reserved | |
| 10 | |
|
4503
65d2d8e67da3
New permission notice, includes CNRI.
Guido van Rossum <guido@python.org>
parents:
4043
diff
changeset
|
11 Permission to use, copy, modify, and distribute this software and its |
|
65d2d8e67da3
New permission notice, includes CNRI.
Guido van Rossum <guido@python.org>
parents:
4043
diff
changeset
|
12 documentation for any purpose and without fee is hereby granted, |
| 145 | 13 provided that the above copyright notice appear in all copies and that |
|
4503
65d2d8e67da3
New permission notice, includes CNRI.
Guido van Rossum <guido@python.org>
parents:
4043
diff
changeset
|
14 both that copyright notice and this permission notice appear in |
| 145 | 15 supporting documentation, and that the names of Stichting Mathematisch |
|
4503
65d2d8e67da3
New permission notice, includes CNRI.
Guido van Rossum <guido@python.org>
parents:
4043
diff
changeset
|
16 Centrum or CWI or Corporation for National Research Initiatives or |
|
65d2d8e67da3
New permission notice, includes CNRI.
Guido van Rossum <guido@python.org>
parents:
4043
diff
changeset
|
17 CNRI not be used in advertising or publicity pertaining to |
|
65d2d8e67da3
New permission notice, includes CNRI.
Guido van Rossum <guido@python.org>
parents:
4043
diff
changeset
|
18 distribution of the software without specific, written prior |
|
65d2d8e67da3
New permission notice, includes CNRI.
Guido van Rossum <guido@python.org>
parents:
4043
diff
changeset
|
19 permission. |
| 145 | 20 |
|
4503
65d2d8e67da3
New permission notice, includes CNRI.
Guido van Rossum <guido@python.org>
parents:
4043
diff
changeset
|
21 While CWI is the initial source for this software, a modified version |
|
65d2d8e67da3
New permission notice, includes CNRI.
Guido van Rossum <guido@python.org>
parents:
4043
diff
changeset
|
22 is made available by the Corporation for National Research Initiatives |
|
65d2d8e67da3
New permission notice, includes CNRI.
Guido van Rossum <guido@python.org>
parents:
4043
diff
changeset
|
23 (CNRI) at the Internet address ftp://ftp.python.org. |
|
65d2d8e67da3
New permission notice, includes CNRI.
Guido van Rossum <guido@python.org>
parents:
4043
diff
changeset
|
24 |
|
65d2d8e67da3
New permission notice, includes CNRI.
Guido van Rossum <guido@python.org>
parents:
4043
diff
changeset
|
25 STICHTING MATHEMATISCH CENTRUM AND CNRI DISCLAIM ALL WARRANTIES WITH |
|
65d2d8e67da3
New permission notice, includes CNRI.
Guido van Rossum <guido@python.org>
parents:
4043
diff
changeset
|
26 REGARD TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF |
|
65d2d8e67da3
New permission notice, includes CNRI.
Guido van Rossum <guido@python.org>
parents:
4043
diff
changeset
|
27 MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL STICHTING MATHEMATISCH |
|
65d2d8e67da3
New permission notice, includes CNRI.
Guido van Rossum <guido@python.org>
parents:
4043
diff
changeset
|
28 CENTRUM OR CNRI BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL |
|
65d2d8e67da3
New permission notice, includes CNRI.
Guido van Rossum <guido@python.org>
parents:
4043
diff
changeset
|
29 DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR |
|
65d2d8e67da3
New permission notice, includes CNRI.
Guido van Rossum <guido@python.org>
parents:
4043
diff
changeset
|
30 PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER |
|
65d2d8e67da3
New permission notice, includes CNRI.
Guido van Rossum <guido@python.org>
parents:
4043
diff
changeset
|
31 TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR |
|
65d2d8e67da3
New permission notice, includes CNRI.
Guido van Rossum <guido@python.org>
parents:
4043
diff
changeset
|
32 PERFORMANCE OF THIS SOFTWARE. |
| 145 | 33 |
| 34 ******************************************************************/ | |
| 35 | |
|
1796
b711c9010232
No need to define THINK_C any more
Guido van Rossum <guido@python.org>
parents:
1794
diff
changeset
|
36 /* Include nearly all Python header files */ |
| 86 | 37 |
|
1746
1940892d2fe3
Merge alpha100 branch back to main trunk
Guido van Rossum <guido@python.org>
parents:
1369
diff
changeset
|
38 #include "config.h" |
|
1940892d2fe3
Merge alpha100 branch back to main trunk
Guido van Rossum <guido@python.org>
parents:
1369
diff
changeset
|
39 |
|
3576
4ec1cac342dd
Non-trivial DL_IMPORT must now be defined in config.h.
Guido van Rossum <guido@python.org>
parents:
3317
diff
changeset
|
40 /* config.h may or may not define DL_IMPORT */ |
|
4ec1cac342dd
Non-trivial DL_IMPORT must now be defined in config.h.
Guido van Rossum <guido@python.org>
parents:
3317
diff
changeset
|
41 #ifndef DL_IMPORT /* declarations for DLL import/export */ |
|
4ec1cac342dd
Non-trivial DL_IMPORT must now be defined in config.h.
Guido van Rossum <guido@python.org>
parents:
3317
diff
changeset
|
42 #define DL_IMPORT(RTYPE) RTYPE |
|
4ec1cac342dd
Non-trivial DL_IMPORT must now be defined in config.h.
Guido van Rossum <guido@python.org>
parents:
3317
diff
changeset
|
43 #endif |
|
4ec1cac342dd
Non-trivial DL_IMPORT must now be defined in config.h.
Guido van Rossum <guido@python.org>
parents:
3317
diff
changeset
|
44 |
|
2792
af3aab6b07c4
Changed ifdef __CFM68K__ to ifdef SYMANTEC__CFM68K__: CW has its own
Jack Jansen <jack.jansen@cwi.nl>
parents:
2436
diff
changeset
|
45 #ifdef SYMANTEC__CFM68K__ |
|
2373
582b00fbab16
changes for Mac CFM-68K
Guido van Rossum <guido@python.org>
parents:
2304
diff
changeset
|
46 #define UsingSharedLibs |
|
582b00fbab16
changes for Mac CFM-68K
Guido van Rossum <guido@python.org>
parents:
2304
diff
changeset
|
47 #endif |
|
582b00fbab16
changes for Mac CFM-68K
Guido van Rossum <guido@python.org>
parents:
2304
diff
changeset
|
48 |
| 86 | 49 #include <stdio.h> |
|
87
ef2440f24f10
Include <string.h> instead of "string.h".
Guido van Rossum <guido@python.org>
parents:
86
diff
changeset
|
50 #include <string.h> |
|
2129
05360cd616ae
The great renaming, phase two: all header files have been updated to
Guido van Rossum <guido@python.org>
parents:
2058
diff
changeset
|
51 #include <errno.h> |
|
3576
4ec1cac342dd
Non-trivial DL_IMPORT must now be defined in config.h.
Guido van Rossum <guido@python.org>
parents:
3317
diff
changeset
|
52 #ifdef HAVE_STDLIB_H |
|
4ec1cac342dd
Non-trivial DL_IMPORT must now be defined in config.h.
Guido van Rossum <guido@python.org>
parents:
3317
diff
changeset
|
53 #include <stdlib.h> |
|
4ec1cac342dd
Non-trivial DL_IMPORT must now be defined in config.h.
Guido van Rossum <guido@python.org>
parents:
3317
diff
changeset
|
54 #endif |
| 86 | 55 |
|
1746
1940892d2fe3
Merge alpha100 branch back to main trunk
Guido van Rossum <guido@python.org>
parents:
1369
diff
changeset
|
56 #include "myproto.h" |
| 86 | 57 |
|
2792
af3aab6b07c4
Changed ifdef __CFM68K__ to ifdef SYMANTEC__CFM68K__: CW has its own
Jack Jansen <jack.jansen@cwi.nl>
parents:
2436
diff
changeset
|
58 #ifdef SYMANTEC__CFM68K__ |
|
2373
582b00fbab16
changes for Mac CFM-68K
Guido van Rossum <guido@python.org>
parents:
2304
diff
changeset
|
59 #pragma lib_export on |
|
582b00fbab16
changes for Mac CFM-68K
Guido van Rossum <guido@python.org>
parents:
2304
diff
changeset
|
60 #endif |
|
582b00fbab16
changes for Mac CFM-68K
Guido van Rossum <guido@python.org>
parents:
2304
diff
changeset
|
61 |
| 86 | 62 #include "object.h" |
| 63 #include "objimpl.h" | |
| 64 | |
|
3576
4ec1cac342dd
Non-trivial DL_IMPORT must now be defined in config.h.
Guido van Rossum <guido@python.org>
parents:
3317
diff
changeset
|
65 #include "pydebug.h" |
|
4ec1cac342dd
Non-trivial DL_IMPORT must now be defined in config.h.
Guido van Rossum <guido@python.org>
parents:
3317
diff
changeset
|
66 |
|
1288
9fed5726a36d
Several changes in one:
Guido van Rossum <guido@python.org>
parents:
1198
diff
changeset
|
67 #include "accessobject.h" |
| 86 | 68 #include "intobject.h" |
| 222 | 69 #include "longobject.h" |
| 86 | 70 #include "floatobject.h" |
|
3317
e4f57dd3d246
added complex and c object.h; get rid of Py_FatalError
Guido van Rossum <guido@python.org>
parents:
3074
diff
changeset
|
71 #ifndef WITHOUT_COMPLEX |
|
e4f57dd3d246
added complex and c object.h; get rid of Py_FatalError
Guido van Rossum <guido@python.org>
parents:
3074
diff
changeset
|
72 #include "complexobject.h" |
|
e4f57dd3d246
added complex and c object.h; get rid of Py_FatalError
Guido van Rossum <guido@python.org>
parents:
3074
diff
changeset
|
73 #endif |
|
1369
89e1e5d9ccbf
* compile.[ch]: support for lambda()
Guido van Rossum <guido@python.org>
parents:
1329
diff
changeset
|
74 #include "rangeobject.h" |
| 86 | 75 #include "stringobject.h" |
| 76 #include "tupleobject.h" | |
| 77 #include "listobject.h" | |
|
2146
9afdbf944c2a
new names for lots of new functions
Guido van Rossum <guido@python.org>
parents:
2129
diff
changeset
|
78 #include "mappingobject.h" |
| 86 | 79 #include "methodobject.h" |
| 80 #include "moduleobject.h" | |
| 81 #include "funcobject.h" | |
| 82 #include "classobject.h" | |
| 83 #include "fileobject.h" | |
|
3317
e4f57dd3d246
added complex and c object.h; get rid of Py_FatalError
Guido van Rossum <guido@python.org>
parents:
3074
diff
changeset
|
84 #include "cobject.h" |
|
3576
4ec1cac342dd
Non-trivial DL_IMPORT must now be defined in config.h.
Guido van Rossum <guido@python.org>
parents:
3317
diff
changeset
|
85 #include "traceback.h" |
| 3829 | 86 #include "sliceobject.h" |
| 86 | 87 |
|
3960
90f5055550d9
Renamed errors. -> pyerrors.h (for Mac, where Errors.h is a system header).
Guido van Rossum <guido@python.org>
parents:
3911
diff
changeset
|
88 #include "pyerrors.h" |
|
978
13c99eaf32a8
* renamed malloc.h mymalloc.h, and added MALLARG as the type of the
Guido van Rossum <guido@python.org>
parents:
790
diff
changeset
|
89 #include "mymalloc.h" |
| 86 | 90 |
|
1329
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1288
diff
changeset
|
91 #include "modsupport.h" |
|
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1288
diff
changeset
|
92 #include "ceval.h" |
|
3576
4ec1cac342dd
Non-trivial DL_IMPORT must now be defined in config.h.
Guido van Rossum <guido@python.org>
parents:
3317
diff
changeset
|
93 #include "pythonrun.h" |
|
4ec1cac342dd
Non-trivial DL_IMPORT must now be defined in config.h.
Guido van Rossum <guido@python.org>
parents:
3317
diff
changeset
|
94 #include "sysmodule.h" |
|
4ec1cac342dd
Non-trivial DL_IMPORT must now be defined in config.h.
Guido van Rossum <guido@python.org>
parents:
3317
diff
changeset
|
95 #include "intrcheck.h" |
|
4ec1cac342dd
Non-trivial DL_IMPORT must now be defined in config.h.
Guido van Rossum <guido@python.org>
parents:
3317
diff
changeset
|
96 #include "import.h" |
|
4ec1cac342dd
Non-trivial DL_IMPORT must now be defined in config.h.
Guido van Rossum <guido@python.org>
parents:
3317
diff
changeset
|
97 #include "bltinmodule.h" |
|
1329
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1288
diff
changeset
|
98 |
| 2839 | 99 #include "abstract.h" |
| 100 | |
|
2129
05360cd616ae
The great renaming, phase two: all header files have been updated to
Guido van Rossum <guido@python.org>
parents:
2058
diff
changeset
|
101 #define PyArg_GetInt(v, a) PyArg_Parse((v), "i", (a)) |
|
05360cd616ae
The great renaming, phase two: all header files have been updated to
Guido van Rossum <guido@python.org>
parents:
2058
diff
changeset
|
102 #define PyArg_NoArgs(v) PyArg_Parse(v, "") |
|
1329
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1288
diff
changeset
|
103 |
| 2304 | 104 /* Convert a possibly signed character to a nonnegative int */ |
| 105 /* XXX This assumes characters are 8 bits wide */ | |
| 106 #ifdef __CHAR_UNSIGNED__ | |
| 107 #define Py_CHARMASK(c) (c) | |
| 108 #else | |
| 109 #define Py_CHARMASK(c) ((c) & 0xff) | |
| 110 #endif | |
| 111 | |
|
2129
05360cd616ae
The great renaming, phase two: all header files have been updated to
Guido van Rossum <guido@python.org>
parents:
2058
diff
changeset
|
112 #ifndef Py_USE_NEW_NAMES |
|
05360cd616ae
The great renaming, phase two: all header files have been updated to
Guido van Rossum <guido@python.org>
parents:
2058
diff
changeset
|
113 #include "rename2.h" |
|
05360cd616ae
The great renaming, phase two: all header files have been updated to
Guido van Rossum <guido@python.org>
parents:
2058
diff
changeset
|
114 #endif |
|
05360cd616ae
The great renaming, phase two: all header files have been updated to
Guido van Rossum <guido@python.org>
parents:
2058
diff
changeset
|
115 |
|
1329
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1288
diff
changeset
|
116 #endif /* !Py_ALLOBJECTS_H */ |
