[Python-checkins] r54900 - in python/branches/bcannon-objcap: Modules/interpretermodule.c interpretermodule.c (original) (raw)

brett.cannon python-checkins at python.org
Sat Apr 21 02:24:07 CEST 2007


Author: brett.cannon Date: Sat Apr 21 02:24:04 2007 New Revision: 54900

Added: python/branches/bcannon-objcap/interpretermodule.c - copied unchanged from r54895, python/branches/bcannon-objcap/Modules/interpretermodule.c Removed: python/branches/bcannon-objcap/Modules/interpretermodule.c Log: Move interpreter module as it currently does not build and is not needed.

Deleted: /python/branches/bcannon-objcap/Modules/interpretermodule.c

--- /python/branches/bcannon-objcap/Modules/interpretermodule.c Sat Apr 21 02:24:04 2007 +++ (empty file) @@ -1,376 +0,0 @@ -#include "Python.h" -#include "interpreter.h" -#include "cStringIO.h"

-static struct PycStringIO_CAPI* PycStringIO = NULL;

-#define PyInterpreter_GET_INTERP(interp)
- (((PyInterpreterObject *)interp)->istate)

-/* - Destroy the interpreter and dealloc memory. -*/ -static void -interpreter_dealloc(PyObject *self) -{ - PyThreadState *new_tstate = NULL; - PyThreadState *cur_tstate = NULL;

-}

-/* - Create a new interpreter. -*/ -static PyObject * -interpreter_new(PyTypeObject *type, PyObject *args, PyObject *kwds) -{ - PyInterpreterObject *self; - PyThreadState *cur_tstate;

-}

-/* - Getter for 'builtins'.

-}

-/* - Getter for 'sys_dict'.

-}

-/* - Execute Python source code in the interpreter. -*/ -static PyObject * -interpreter_exec(PyInterpreterObject *self, PyObject *arg) -{ - const char str_arg = NULL; - PyThreadState cur_tstate = NULL; - PyObject *main_module = NULL; - PyObject *main_dict = NULL; - PyObject *result = NULL; - const char *exc_name = NULL;

-}

-static PyObject * -redirect_output(PyObject *self, PyObject *args) -{ - PyObject *py_stdout = NULL; - PyObject *py_stderr = NULL; - PyObject *used_stdout_stderr = NULL;

-}

-static PyObject * -exc_matches(PyInterpreterObject *self, PyObject *arg) -{ - PyThreadState *starting_tstate = NULL; - PyObject *raised_exc = NULL; - int result = 0;

-}

-static PyMethodDef interpreter_methods[] = { - {"builtins", (PyCFunction)interpreter_builtins, METH_NOARGS, - "Return the built-in namespace dict."}, - {"sys_dict", (PyCFunction)interpreter_sys_dict, METH_NOARGS, - "Return the 'sys' module's data dictionary."}, - {"execute", (PyCFunction)interpreter_exec, METH_O, - "Execute the passed-in string in the interpreter."}, - {"redirect_output", (PyCFunction)redirect_output, METH_VARARGS, - "Redirect stdout to stderr. Returns tuple of objects used."}, - {"exc_matches", (PyCFunction)exc_matches, METH_O, - "Check if the raised exception in the interpreter matches the argument"}, - {NULL} -};

-}



More information about the Python-checkins mailing list