Mercurial > cpython-lru_cache-weakref
annotate Include/pythonrun.h @ 13255:916fb024ce94 legacy-trunk
Change copyright notice.
| author | Guido van Rossum <guido@python.org> |
|---|---|
| date | Fri, 30 Jun 2000 23:50:40 +0000 |
| parents | 1dac89bbbcd2 |
| children | 87ee82e5c56d |
| rev | line source |
|---|---|
|
1329
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1313
diff
changeset
|
1 #ifndef Py_PYTHONRUN_H |
|
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1313
diff
changeset
|
2 #define Py_PYTHONRUN_H |
|
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1313
diff
changeset
|
3 #ifdef __cplusplus |
|
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1313
diff
changeset
|
4 extern "C" { |
|
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1313
diff
changeset
|
5 #endif |
|
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1313
diff
changeset
|
6 |
| 145 | 7 /*********************************************************** |
| 2058 | 8 Copyright 1991-1995 by Stichting Mathematisch Centrum, Amsterdam, |
| 9 The Netherlands. | |
| 145 | 10 |
| 11 All Rights Reserved | |
| 12 | |
|
13255
916fb024ce94
Change copyright notice.
Guido van Rossum <guido@python.org>
parents:
13020
diff
changeset
|
13 Copyright (c) 2000, BeOpen.com. |
|
916fb024ce94
Change copyright notice.
Guido van Rossum <guido@python.org>
parents:
13020
diff
changeset
|
14 Copyright (c) 1995-2000, Corporation for National Research Initiatives. |
|
916fb024ce94
Change copyright notice.
Guido van Rossum <guido@python.org>
parents:
13020
diff
changeset
|
15 Copyright (c) 1990-1995, Stichting Mathematisch Centrum. |
|
916fb024ce94
Change copyright notice.
Guido van Rossum <guido@python.org>
parents:
13020
diff
changeset
|
16 All rights reserved. |
| 145 | 17 |
|
13255
916fb024ce94
Change copyright notice.
Guido van Rossum <guido@python.org>
parents:
13020
diff
changeset
|
18 See the file "Misc/COPYRIGHT" for information on usage and |
|
916fb024ce94
Change copyright notice.
Guido van Rossum <guido@python.org>
parents:
13020
diff
changeset
|
19 redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES. |
| 145 | 20 |
| 21 ******************************************************************/ | |
| 22 | |
| 86 | 23 /* Interfaces to parse and execute pieces of python code */ |
| 24 | |
|
9586
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
25 DL_IMPORT(void) Py_SetProgramName Py_PROTO((char *)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
26 DL_IMPORT(char *) Py_GetProgramName Py_PROTO((void)); |
|
5862
4dbb4ec44d15
Added declarations for Py_{Set,Get}ProgramName() and a bunch of other
Guido van Rossum <guido@python.org>
parents:
5111
diff
changeset
|
27 |
|
9586
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
28 DL_IMPORT(void) Py_SetPythonHome Py_PROTO((char *)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
29 DL_IMPORT(char *) Py_GetPythonHome Py_PROTO((void)); |
|
7208
ce271e5f9bc5
- Add Py_GetPythonHome() and Py_SetPythonHome(), intended to allow
Guido van Rossum <guido@python.org>
parents:
6192
diff
changeset
|
30 |
|
9586
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
31 DL_IMPORT(void) Py_Initialize Py_PROTO((void)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
32 DL_IMPORT(void) Py_Finalize Py_PROTO((void)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
33 DL_IMPORT(int) Py_IsInitialized Py_PROTO((void)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
34 DL_IMPORT(PyThreadState *) Py_NewInterpreter Py_PROTO((void)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
35 DL_IMPORT(void) Py_EndInterpreter Py_PROTO((PyThreadState *)); |
| 86 | 36 |
|
9586
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
37 DL_IMPORT(int) PyRun_AnyFile Py_PROTO((FILE *, char *)); |
| 86 | 38 |
|
9586
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
39 DL_IMPORT(int) PyRun_SimpleString Py_PROTO((char *)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
40 DL_IMPORT(int) PyRun_SimpleFile Py_PROTO((FILE *, char *)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
41 DL_IMPORT(int) PyRun_InteractiveOne Py_PROTO((FILE *, char *)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
42 DL_IMPORT(int) PyRun_InteractiveLoop Py_PROTO((FILE *, char *)); |
| 86 | 43 |
|
9586
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
44 DL_IMPORT(struct _node *) PyParser_SimpleParseString Py_PROTO((char *, int)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
45 DL_IMPORT(struct _node *) PyParser_SimpleParseFile Py_PROTO((FILE *, char *, int)); |
| 86 | 46 |
|
9586
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
47 DL_IMPORT(PyObject *) PyRun_String Py_PROTO((char *, int, PyObject *, PyObject *)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
48 DL_IMPORT(PyObject *) PyRun_File Py_PROTO((FILE *, char *, int, PyObject *, PyObject *)); |
| 86 | 49 |
|
9586
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
50 DL_IMPORT(PyObject *) Py_CompileString Py_PROTO((char *, char *, int)); |
|
1263
65a1e4e9cd54
* Fixed some subtleties with fastlocals. You can no longer access
Guido van Rossum <guido@python.org>
parents:
1257
diff
changeset
|
51 |
|
9586
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
52 DL_IMPORT(void) PyErr_Print Py_PROTO((void)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
53 DL_IMPORT(void) PyErr_PrintEx Py_PROTO((int)); |
| 86 | 54 |
|
9586
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
55 DL_IMPORT(int) Py_AtExit Py_PROTO((void (*func) Py_PROTO((void)))); |
|
1868
63ad28939781
pythgonrun.h: added Py_AtExit().
Guido van Rossum <guido@python.org>
parents:
1746
diff
changeset
|
56 |
|
9586
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
57 DL_IMPORT(void) Py_Exit Py_PROTO((int)); |
|
1329
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1313
diff
changeset
|
58 |
|
9586
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
59 DL_IMPORT(int) Py_FdIsInteractive Py_PROTO((FILE *, char *)); |
|
5111
21b871325c85
Added decl for Py_FdIsInteractive.
Guido van Rossum <guido@python.org>
parents:
4503
diff
changeset
|
60 |
|
5862
4dbb4ec44d15
Added declarations for Py_{Set,Get}ProgramName() and a bunch of other
Guido van Rossum <guido@python.org>
parents:
5111
diff
changeset
|
61 /* In getpath.c */ |
|
9586
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
62 DL_IMPORT(char *) Py_GetProgramFullPath Py_PROTO((void)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
63 DL_IMPORT(char *) Py_GetPrefix Py_PROTO((void)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
64 DL_IMPORT(char *) Py_GetExecPrefix Py_PROTO((void)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
65 DL_IMPORT(char *) Py_GetPath Py_PROTO((void)); |
|
5862
4dbb4ec44d15
Added declarations for Py_{Set,Get}ProgramName() and a bunch of other
Guido van Rossum <guido@python.org>
parents:
5111
diff
changeset
|
66 |
|
4dbb4ec44d15
Added declarations for Py_{Set,Get}ProgramName() and a bunch of other
Guido van Rossum <guido@python.org>
parents:
5111
diff
changeset
|
67 /* In their own files */ |
|
9586
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
68 DL_IMPORT(const char *) Py_GetVersion Py_PROTO((void)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
69 DL_IMPORT(const char *) Py_GetPlatform Py_PROTO((void)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
70 DL_IMPORT(const char *) Py_GetCopyright Py_PROTO((void)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
71 DL_IMPORT(const char *) Py_GetCompiler Py_PROTO((void)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
72 DL_IMPORT(const char *) Py_GetBuildInfo Py_PROTO((void)); |
|
5862
4dbb4ec44d15
Added declarations for Py_{Set,Get}ProgramName() and a bunch of other
Guido van Rossum <guido@python.org>
parents:
5111
diff
changeset
|
73 |
|
5919
5da18e002b1a
Mass checkin (more to follow for other directories).
Guido van Rossum <guido@python.org>
parents:
5862
diff
changeset
|
74 /* Internal -- various one-time initializations */ |
|
12753
86ec75dac272
Now that standard exceptions are builtin, we don't need two phase init
Barry Warsaw <barry@python.org>
parents:
9586
diff
changeset
|
75 DL_IMPORT(PyObject *) _PyBuiltin_Init Py_PROTO((void)); |
|
9586
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
76 DL_IMPORT(PyObject *) _PySys_Init Py_PROTO((void)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
77 DL_IMPORT(void) _PyImport_Init Py_PROTO((void)); |
|
12753
86ec75dac272
Now that standard exceptions are builtin, we don't need two phase init
Barry Warsaw <barry@python.org>
parents:
9586
diff
changeset
|
78 DL_IMPORT(void) init_exceptions Py_PROTO((void)); |
|
5919
5da18e002b1a
Mass checkin (more to follow for other directories).
Guido van Rossum <guido@python.org>
parents:
5862
diff
changeset
|
79 |
|
5984
b4bbba3af4e8
Added prototype for various finalizers.
Guido van Rossum <guido@python.org>
parents:
5919
diff
changeset
|
80 /* Various internal finalizers */ |
|
12753
86ec75dac272
Now that standard exceptions are builtin, we don't need two phase init
Barry Warsaw <barry@python.org>
parents:
9586
diff
changeset
|
81 DL_IMPORT(void) fini_exceptions Py_PROTO((void)); |
|
13020
1dac89bbbcd2
Fredrik Lundh: get rid of warning in pythonrun.c
Guido van Rossum <guido@python.org>
parents:
12753
diff
changeset
|
82 DL_IMPORT(void) _PyImport_Fini Py_PROTO((void)); |
|
9586
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
83 DL_IMPORT(void) PyMethod_Fini Py_PROTO((void)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
84 DL_IMPORT(void) PyFrame_Fini Py_PROTO((void)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
85 DL_IMPORT(void) PyCFunction_Fini Py_PROTO((void)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
86 DL_IMPORT(void) PyTuple_Fini Py_PROTO((void)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
87 DL_IMPORT(void) PyString_Fini Py_PROTO((void)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
88 DL_IMPORT(void) PyInt_Fini Py_PROTO((void)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
89 DL_IMPORT(void) PyFloat_Fini Py_PROTO((void)); |
|
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
90 DL_IMPORT(void) PyOS_FiniInterrupts Py_PROTO((void)); |
|
5984
b4bbba3af4e8
Added prototype for various finalizers.
Guido van Rossum <guido@python.org>
parents:
5919
diff
changeset
|
91 |
|
5986
32127593c134
Added decls for stuff from myreadline.
Guido van Rossum <guido@python.org>
parents:
5984
diff
changeset
|
92 /* Stuff with no proper home (yet) */ |
|
9586
60fdb1db1175
Add DL_IMPORT(returntype) for all officially exported functions.
Guido van Rossum <guido@python.org>
parents:
7208
diff
changeset
|
93 DL_IMPORT(char *) PyOS_Readline Py_PROTO((char *)); |
|
5986
32127593c134
Added decls for stuff from myreadline.
Guido van Rossum <guido@python.org>
parents:
5984
diff
changeset
|
94 extern DL_IMPORT(int) (*PyOS_InputHook) Py_PROTO((void)); |
|
32127593c134
Added decls for stuff from myreadline.
Guido van Rossum <guido@python.org>
parents:
5984
diff
changeset
|
95 extern DL_IMPORT(char) *(*PyOS_ReadlineFunctionPointer) Py_PROTO((char *)); |
|
32127593c134
Added decls for stuff from myreadline.
Guido van Rossum <guido@python.org>
parents:
5984
diff
changeset
|
96 |
|
1329
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1313
diff
changeset
|
97 #ifdef __cplusplus |
|
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1313
diff
changeset
|
98 } |
|
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1313
diff
changeset
|
99 #endif |
|
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1313
diff
changeset
|
100 #endif /* !Py_PYTHONRUN_H */ |
