Commit Graph

577 Commits

Author SHA1 Message Date
Guido van Rossum bf6a9b165a Add
PySys_WriteStdout(format, ...)
   PySys_WriteStderr(format, ...)
1998-05-12 14:58:52 +00:00
Guido van Rossum 50cc04ee03 Mac CodeWarrior has faulty declaration for hypot, which we hide with a
#define.
(Jack)
1998-04-28 16:02:29 +00:00
Guido van Rossum a937d14898 Fred's right -- we need PyList_SET_ITEM(). 1998-04-24 18:22:02 +00:00
Guido van Rossum a9c2d7a87c Add new spares to the end of the type object struct. 1998-04-23 19:16:44 +00:00
Guido van Rossum ee0a63bec5 Move 'dict' struct member to end of struct. This ensures binary
compatibility for shared libraries.

*** WARNING -- IF YOU BUILT 1.5.1BETA1, DO A "MAKE CLEAN" ***
1998-04-13 20:24:05 +00:00
Guido van Rossum 26d4ac30be Add prototypes for Py_Repr{Enter,Leave}.
(Jeremy will hardly recognize his patch :-)
1998-04-10 22:32:24 +00:00
Guido van Rossum 204751b127 Add dict struct member and PyThreadState_GetDict() prototype. 1998-04-10 20:19:01 +00:00
Guido van Rossum c9ea7572e9 Set the patch level to 1.5.1. (I'm not going to release this as a
beta -- if there are bugs, I'll post a patch page and release 1.5.2
sooner.)
1998-04-10 18:08:06 +00:00
Guido van Rossum 4d856ee652 Added Tabcheck flag. 1998-04-10 17:59:44 +00:00
Guido van Rossum e77a992a0d Add E_INDENT -- new error to check for bad indentation 1998-04-09 21:37:20 +00:00
Guido van Rossum c3d3f9692d Add PyObject_Not(). 1998-04-09 17:53:59 +00:00
Guido van Rossum f1dc0615e9 Add internal routine _PyModule_Clear(), which does approximately what
clear_carefully() used to do in import.c.  Differences: leave only
__builtins__ alone in the 2nd pass; and don't clear the dictionary (on
the theory that as long as there are references left to the
dictionary, those might be destructors that might expect __builtins__
to be alive when they run; and __builtins__ can't normally be part of
a cycle).
1998-02-19 20:51:52 +00:00
Guido van Rossum fccb68ef2a Added PyImport_ExecCodeModuleEx(), which adds an extra parameter to pass
it the true file.
1998-02-11 05:47:24 +00:00
Guido van Rossum 66d4b90791 - Add Py_GetPythonHome() and Py_SetPythonHome(), intended to allow
embedders to force a different PYTHONHOME.

- Add new interface PyErr_PrintEx(flag); same as PyErr_Print() but
flag determines whether sys.last_* are set or not.  PyErr_Print()
now simply calls PyErr_PrintEx(1).
1998-02-06 22:28:05 +00:00
Guido van Rossum 95c745b5fc - Add Py_FrozenFlag, intended to suppress error messages fron
getpath.c in frozen binaries.
1998-02-06 22:27:46 +00:00
Guido van Rossum d8a0be775f Set the patch level to 1.5. 1997-12-30 04:29:49 +00:00
Guido van Rossum d5559576c9 Start calling it 1.5b2 1997-12-10 05:51:13 +00:00
Guido van Rossum cd8732a482 Remove the last bits of log from the leading comments. 1997-12-08 15:16:08 +00:00
Guido van Rossum 60aff2c0a6 Use the proper OS2 test symbol: PYOS_OS2. 1997-12-05 21:39:25 +00:00
Guido van Rossum 36facb086e Merge between my version and Jim Fulton's version; removed RCS keywords
but otherwise unchanged.
1997-12-04 01:14:08 +00:00
Guido van Rossum 7bf22de753 Patch for QNX, by Chris Herborth. 1997-12-02 20:34:19 +00:00
Guido van Rossum 8e9ebfd337 os2 patch by Jeff Rush 1997-11-22 21:53:48 +00:00
Guido van Rossum ee6fd1c392 Add declaration for _Py_PackageContext -- needed to fix importing
of shared libraries from inside packages.
1997-11-19 18:51:35 +00:00
Guido van Rossum 127b8dd8d4 Add declaration for PyNumber_CoerceEx(). 1997-11-19 16:04:54 +00:00
Guido van Rossum 33635f818a start numbering things 1.5b1 now 1997-11-18 19:21:47 +00:00
Guido van Rossum 359bcaa539 This fix (across 4 files in 3 directories) solves a subtle problem with
signal handlers in a fork()ed child process when Python is compiled with
thread support.  The bug was reported by Scott <scott@chronis.icgroup.com>.

What happens is that after a fork(), the variables used by the signal
module to determine whether this is the main thread or not are bogus,
and it decides that no thread is the main thread, so no signals will
be delivered.

The solution is the addition of PyOS_AfterFork(), which fixes the signal
module's variables.  A dummy version of the function is present in the
intrcheck.c source file which is linked when the signal module is not
used.
1997-11-14 22:24:28 +00:00
Guido van Rossum 66959aff68 Remove the declaration of "internal" table _PyImport_Inittab[]; add
new "official" pointer *PyImport_Inittab.
1997-10-31 18:36:47 +00:00
Guido van Rossum 1f84449fd8 New CObject from Jim Fulton, adds PyCObject_FromVoidPtrAndDesc() and
PyCObject_GetDesc().
1997-10-21 19:48:35 +00:00
Guido van Rossum e85da651dd Some patches to Lee Busby's fpectl mods that accidentally didn't make it
into 1.5a4.
1997-10-20 23:50:01 +00:00
Guido van Rossum eec6ef1aa2 Use K&R function prototypes. 1997-10-07 14:44:48 +00:00
Guido van Rossum b4cfdfa077 Removed special Windows defines, at Mark Hammond's request. 1997-09-29 23:29:08 +00:00
Guido van Rossum 2d2c34445b New API PyErr_NewException(name, base, dict) to create simple new exceptions. 1997-09-16 21:50:37 +00:00
Barry Warsaw 65349a3936 [Py_Exc]NumberError => [Py_Exc]ArithmeticError 1997-09-16 21:50:36 +00:00
Guido van Rossum 0474832d9c Introduce PyExc_Exception as the conceptual root class for all exceptions. 1997-09-16 18:43:15 +00:00
Guido van Rossum 7ca65abb2f Set it to 1.5a4, now we have dotted-name import... 1997-09-08 02:17:31 +00:00
Guido van Rossum 114c1eabbb #Added prototype for PyObject_HasAttr() -- must've been an oversight. 1997-09-06 18:44:59 +00:00
Fred Drake 49bb0e32a0 Fix in trailing comment: PyDict_SetItemString() does *not* consume a reference
count, PyList_SetItem() does.  Very confusing!
1997-09-05 17:53:53 +00:00
Guido van Rossum 026de19906 Added PyImport_ImportModuleEx(name, globals, locals, fromlist); this
is like PyImport_ImporModule(name) but receives the globals and locals
dict and the fromlist arguments as well.  (The name is a char*; the
others are PyObject*s).
1997-09-05 07:11:32 +00:00
Guido van Rossum d7ed683a7e Inline PyObject_CallObject (Marc-Andre Lemburg). 1997-08-30 15:02:50 +00:00
Guido van Rossum 3d90af967d Added NoSite flag. 1997-08-29 22:34:00 +00:00
Barry Warsaw d5a0ff972d Added extern definition for -X flag variable. 1997-08-29 22:01:11 +00:00
Barry Warsaw 0596c2ac28 Declarations for two phase initialization and finalization functions
for the built-in module.
1997-08-29 21:57:07 +00:00
Barry Warsaw 392d8272bf Added externs for three new exceptions PyExc_StandardError,
PyExc_NumberError, and PyExc_LookupError.  Also added extern for
pre-instantiated exception instance PyExc_MemoryErrorInst.

Removed extern of obsolete exception PyExc_AccessError.
1997-08-29 21:56:07 +00:00
Barry Warsaw c0dc92af7d Three new C API functions:
- int PyErr_GivenExceptionMatches(obj1, obj2)

  Returns 1 if obj1 and obj2 are the same object, or if obj1 is an
  instance of type obj2, or of a class derived from obj2

- int PyErr_ExceptionMatches(obj)

  Higher level wrapper around PyErr_GivenExceptionMatches() which uses
  PyErr_Occurred() as obj1.  This will be the more commonly called
  function.

- void PyErr_NormalizeException(typeptr, valptr, tbptr)

  Normalizes exceptions, and places the normalized values in the
  arguments.  If type is not a class, this does nothing.  If type is a
  class, then it makes sure that value is an instance of the class by:

  1. if instance is of the type, or a class derived from type, it does
     nothing.

  2. otherwise it instantiates the class, using the value as an
     argument.  If value is None, it uses an empty arg tuple, and if
     the value is a tuple, it uses just that.
1997-08-22 21:22:58 +00:00
Guido van Rossum e3c0d5eb34 Added new Py_IsInitalized() API function to test the 'initialized' flag. 1997-08-22 04:20:13 +00:00
Guido van Rossum ab589b945e Completely disable the declarations for malloc() and friends. Use
#ifdef though, so if you still need these for a really backwards
compiler you know what to do.
1997-08-21 16:13:37 +00:00
Guido van Rossum ef3138f9ad Moved assert.h to ../Parser directory 1997-08-19 12:07:22 +00:00
Guido van Rossum 9faabb8d23 Added prototype for PyImport_Import(). 1997-08-14 19:52:09 +00:00
Guido van Rossum 142eeb8339 cPickle release 0.3 from Jim Fulton 1997-08-13 03:14:41 +00:00
Guido van Rossum 3fb1aea0ae Added decls for stuff from myreadline. 1997-08-12 15:14:22 +00:00
Guido van Rossum 8e5e4461a8 Added prototype for various finalizers. 1997-08-12 14:57:21 +00:00
Guido van Rossum bb301c53ed Added prototype for PyGrammar_RemoveAccelerators(). 1997-08-12 14:57:08 +00:00
Guido van Rossum 15974ad5e6 Bump MS_DLL_ID to 1.5.0. 1997-08-12 14:48:03 +00:00
Guido van Rossum 1d529d1ecd Add a cast to the call to _Py_Dealloc in the expanded version of
Py_DECREF, to reduce the warnings when compiling with reference count
debugging on.  (There are still warnings for each call to
_Py_NewReference -- too bad.)
1997-08-05 02:30:44 +00:00
Guido van Rossum d085e88d3c Added Py_Malloc and friends as well as PyMem_Malloc and friends. 1997-08-05 01:59:22 +00:00
Guido van Rossum 29e46a9a12 Mass checkin (more to follow for other directories).
Introduce truly separate (sub)interpreter objects.  For now, these
must be used by separate threads, created from C.  See Demo/pysvr for
an example of how to use this.  This also rationalizes Python's
initialization and finalization behavior:

Py_Initialize() -- initialize the whole interpreter
Py_Finalize() -- finalize the whole interpreter

tstate = Py_NewInterpreter() -- create a new (sub)interpreter
Py_EndInterpreter(tstate) -- delete a new (sub)interpreter

There are also new interfaces relating to threads and the interpreter
lock, which can be used to create new threads, and sometimes have to
be used to manipulate the interpreter lock when creating or deleting
sub-interpreters.  These are only defined when WITH_THREAD is defined:

PyEval_AcquireLock() -- acquire the interpreter lock
PyEval_ReleaseLock() -- release the interpreter lock

PyEval_AcquireThread(tstate) -- acquire the lock and make the thread current
PyEval_ReleaseThread(tstate) -- release the lock and make NULL current

Other administrative changes:

- The header file bltinmodule.h is deleted.

- The init functions for Import, Sys and Builtin are now internal and
  declared in pythonrun.h.

- Py_Setup() and Py_Cleanup() are no longer declared.

- The interpreter state and thread state structures are now linked
  together in a chain (the chain of interpreters is a static variable
  in pythonrun.c).

- Some members of the interpreter and thread structures have new,
  shorter, more consistent, names.

- Added declarations for _PyImport_{Find,Fixup}Extension() to import.h.
1997-08-02 02:56:48 +00:00
Guido van Rossum 7a2d6112d9 Add cast to PyInt_AS_LONG macro, as suggested by Marc Lemburg. 1997-08-02 02:41:13 +00:00
Guido van Rossum 2981bc7a65 Add cast to PyFloat_AS_DOUBLE macro, as suggested by Marc Lemburg. 1997-08-02 02:40:58 +00:00
Guido van Rossum 766118525a Changed the patch level to 1.5a3, to avoid confusion with a2 (I'm not
ready for a release yet).
1997-07-19 23:46:59 +00:00
Guido van Rossum 57d8e3f1c7 Added declarations for Py_{Set,Get}ProgramName() and a bunch of other
Py_Get*() functions.
1997-07-19 19:50:52 +00:00
Guido van Rossum 5617f32c5c Added decl for PyInt_GetMax(). 1997-07-19 19:49:11 +00:00
Guido van Rossum a847889607 Moved PyEval_InitThreads to inside WITH_THREAD, where it belongs. 1997-07-19 19:27:30 +00:00
Guido van Rossum e6fb2043ce Got rid of "suppres printing" flag. 1997-07-19 19:26:38 +00:00
Guido van Rossum 618af4b3ef Include pystate.h earlier so it can be referenced by ceval.h. 1997-07-18 23:59:26 +00:00
Guido van Rossum 2fca21f762 PyEval_SaveThread() and PyEval_RestoreThread() now return/take a
PyThreadState pointer instead of a (frame) PyObject pointer.  This
makes much more sense.  It is backward incompatible, but that's no
problem, because (a) the heaviest users are the Py_{BEGIN,END}_
ALLOW_THREADS macros here, which have been fixed too; (b) there are
very few direct users; (c) those who use it are there will probably
appreciate the change.

Also, added new functions PyEval_AcquireThread() and
PyEval_ReleaseThread() which allows the threads created by the thread
module as well threads created by others (!) to set/reset the current
thread, and at the same time acquire/release the interpreter lock.

Much saner.
1997-07-18 23:56:58 +00:00
Guido van Rossum 4b11c74f7c Only add 1 byte to all malloc calls when it is known that malloc(0) or
realloc(p, 0) returns NULL.  See changes to configure script to be
checked in later.
1997-07-10 22:40:54 +00:00
Guido van Rossum 745b8cff08 flushline and writestring can now return an error 1997-05-22 22:23:46 +00:00
Guido van Rossum 59943ba718 Added Py_PROTO macros for SunOS 4.x /bin/cc. 1997-05-20 22:07:46 +00:00
Guido van Rossum c23ef0a6e8 Workaround for bug in Metrowerks MSL headers on 68K Macs (Jack) 1997-05-20 15:58:15 +00:00
Guido van Rossum d0c87ee6c4 Oops, another forgotten renaming: varobject -> PyVarObject. 1997-05-15 21:31:03 +00:00
Guido van Rossum 4346716962 Bump level to 1.5a2. 1997-05-14 21:41:46 +00:00
Guido van Rossum 2ec9031b55 Subsumed mappingobject.h in dictobject.h. 1997-05-13 21:23:32 +00:00
Guido van Rossum 6a33de9526 Get rid of obsolete ACCESS_MODE opcode. 1997-05-09 00:39:04 +00:00
Guido van Rossum 6778f257b7 Oops, rename2.h was included by some other headers. 1997-05-07 23:50:40 +00:00
Guido van Rossum b05a5c7698 Instead of importing graminit.h whenever one of the three grammar 'root'
symbols is needed, define these in Python.h with a Py_ prefix.
1997-05-07 17:46:13 +00:00
Guido van Rossum fdf95dd525 Checkin of Jack's buffer mods.
Not really checked, but didn't fail any tests either...
1997-05-05 22:15:02 +00:00
Guido van Rossum a027efa5bf Massive changes for separate thread state management.
All per-thread globals are moved into a struct which is manipulated
separately.
1997-05-05 20:56:21 +00:00
Guido van Rossum 4a43cc67db Remove sys_* defines that are internal only and about to disappear 1997-05-05 20:46:18 +00:00
Guido van Rossum 84bf42531c Finally deleted this obsolete crud. 1997-05-02 04:01:08 +00:00
Guido van Rossum d27b4f2a3f Several oopsies -- Py_ALLOBJECTS_H -> Py_PYTHON_H, temporarily removed
pystate.h (to be restored later when that code is debugged), removed
accessobject.h.
1997-05-02 04:00:11 +00:00
Guido van Rossum 174f95adf7 Moved allobjects.h to Python.h (without rename2.h).
allobjects.h disappears -- old-style extensions must include Python.h
and rename2.h.
1997-05-02 03:55:52 +00:00
Guido van Rossum 87490eb3b0 Renamed inittab. 1997-04-29 20:31:59 +00:00
Guido van Rossum e601c0f55d Added new name for inittab! 1997-04-29 16:23:44 +00:00
Guido van Rossum 63c35e5407 Remove macros that are only used for cgensupport.[ch].
Fixed typo in PyArg_VaParse (not PyArgs_*).
1997-04-29 16:21:39 +00:00
Guido van Rossum 92e8782217 Moved cgensupport.h to Modules (awaiting oblivion). 1997-04-29 16:08:53 +00:00
Guido van Rossum 1818b7702b Moved rename2's macros relevant to this module here and added comment
about the file's obsolescence.
1997-04-29 15:35:28 +00:00
Guido van Rossum 45c3aaba56 Got rid of the static decl of PyCObject_Import, which was a 1.4
compatibility hack.
1997-04-09 18:04:08 +00:00
Guido van Rossum 0a73dd5f35 Changed the way the C API was exported. Jim Fulton. 1997-04-09 17:34:28 +00:00
Guido van Rossum 8ecd1ad785 Added assert grammar. 1997-04-02 05:24:08 +00:00
Guido van Rossum 6fa4466cec Added AssertionError. 1997-04-02 05:22:53 +00:00
Guido van Rossum 94dbd99483 Remove ConflictError (which was also removed from bltinmodule.c, even
though the checkin message failed to note that).
1997-03-31 17:19:40 +00:00
Guido van Rossum e053c67780 Remove err_input -- there is no such global! 1997-03-14 05:09:30 +00:00
Guido van Rossum f0958064f9 Remove redundant references to thread stuff -- long, long ago, there
was some locking code in this file that needed it...
1997-03-14 04:25:22 +00:00
Guido van Rossum 74277916a9 Add Macros defining new names for all external symbols. 1997-03-14 04:24:08 +00:00
Guido van Rossum 1f06beeedd Change PyFPE_END_PROTECT to PyFPE_END_PROTECT(v). v should be the
last variable to which a floating point expression is assigned.  The
macro passes its address to a dummy function so that the optimizer
can't delay calculating its value until after the macro.
1997-03-14 04:23:42 +00:00
Guido van Rossum f39fc43f31 A few comment alignment and clarifications. 1997-03-04 18:31:47 +00:00
Guido van Rossum e9e47796c8 Add global Py_OptimizeFlag. 1997-03-03 19:13:54 +00:00
Guido van Rossum 7d4266ed5a Changes for Lee Busby's SIGFPE patch set.
New file pyfpe.h, new exception FloatingPointError.
1997-02-14 22:53:12 +00:00
Guido van Rossum 1ca407f3e4 Fix the comments for bitwise and/or. 1997-02-14 22:51:40 +00:00
Guido van Rossum 5c4998b236 Added decl for Py_FdIsInteractive. 1997-02-14 19:51:34 +00:00
Guido van Rossum 3f3a2686b8 Added decl for Py_InteractiveFlag. 1997-02-14 19:51:09 +00:00
Guido van Rossum c4193f1547 Added prototype for PyErr_Format(exception, formatstring, ...) -> NULL. 1997-02-14 17:10:25 +00:00
Guido van Rossum 36280a7772 Added PyArg_ParseTupleAndKeywords() prototype. 1997-02-14 16:36:35 +00:00
Guido van Rossum fb76f1af9b djgpp support. 1997-02-14 16:36:08 +00:00
Guido van Rossum 767579854c Add co_firstlineno and co_lnotab, for the line number table generated
by the compiler (in lieu of SET_LINENO instructions).
1997-01-24 03:41:09 +00:00
Guido van Rossum e0e696282f Added PyCObject_Import. 1997-01-22 20:48:48 +00:00
Guido van Rossum c1ef39f795 Bump version to 1.5a1. 1997-01-22 03:46:13 +00:00
Guido van Rossum cdf578ebaf New lay-out of frame object, for fewer mallocs.
See frameobject.c checkin message.
1997-01-20 04:16:40 +00:00
Guido van Rossum ee5cf9b672 Bump API version due to the various speedup hacks. 1997-01-18 07:54:03 +00:00
Guido van Rossum 1e6e9a2368 Two speedup hacks. Caching the hash saves recalculation of a string's
hash value.  Interning strings (which requires hash caching) tries to
ensure that only one string object with a given value exists, so
equality tests are one pointer comparison.  Together, these can speed
the interpreter up by as much as 20%.  Each costs the size of a long
or pointer per string object.  In addition, interned strings live
until the end of times.  If you are concerned about memory footprint,
simply comment the #define out here (and rebuild everything!).
1997-01-18 07:53:23 +00:00
Guido van Rossum 3f6e408a31 Add co_stacksize field to codeobject structure, and stacksize argument
to PyCode_New() argument list.  Also add CO_MAXBLOCKS constant
indicating the maximum static nesting supported by the compiler.
1997-01-17 20:59:26 +00:00
Guido van Rossum d81a1baa5f Jim's latest version 1997-01-06 22:50:12 +00:00
Barry Warsaw 9c5494a1b9 added PyTuple_GET_SIZE macro 1997-01-06 22:44:27 +00:00
Barry Warsaw accfb849f9 added PyString_GET_SIZE macro
for both PyString_GET_SIZE and PyString_AS_STRING, cast first argument
to a PyStringObject*
1997-01-06 22:42:50 +00:00
Barry Warsaw 1f2bd07aed added PyList_GET_SIZE macro
for both PyList_GET_SIZE and PyList_GET_ITEM, cast first argument to a
PyListObject*
1997-01-06 22:42:00 +00:00
Guido van Rossum 53756b1097 Added PyLong_FromUnsignedLong() and PyLong_AsUnsignedLong(). 1997-01-03 17:14:46 +00:00
Barry Warsaw f3f41a9e57 Added declaration for PyErr_SetInterrupt. 1997-01-03 00:15:03 +00:00
Guido van Rossum 408027ea46 Rename DEBUG macro to Py_DEBUG 1996-12-30 16:17:54 +00:00
Guido van Rossum caf783793d Added remaining declarations needed/used in glmodule.c; keeps gcc -Wall happy. 1996-12-10 15:41:19 +00:00
Guido van Rossum 067998f35e Add const to error and newstring functions 1996-12-10 15:33:34 +00:00
Guido van Rossum 049cd90b93 Jim F's brainchild 1996-12-05 23:30:48 +00:00
Guido van Rossum 2adf06b04c Added missing for PySequence_List. 1996-12-05 21:48:50 +00:00
Guido van Rossum d266eb460e New permission notice, includes CNRI. 1996-10-25 14:44:06 +00:00
Guido van Rossum 58055847f4 Changed version to plain "1.4". 1996-10-22 03:09:46 +00:00
Guido van Rossum b75fba04c7 Forget about Ellipses b/w compatibility. 1996-10-16 04:18:36 +00:00
Guido van Rossum e449af7da9 Ellipses -> Ellipsis rename (the dictionary really says that it should
be Ellipsis!).
Bumped the API version because a linker-visible symbol is affected.
Old C code will still compile -- there's a b/w compat macro.
Similarly, old Python code will still run, builtin exports both
Ellipses and Ellipsis.
1996-10-11 16:25:41 +00:00
Guido van Rossum a63518436a Add waitflag to down_sema(). 1996-10-08 14:21:49 +00:00
Guido van Rossum c8ce571c16 Rationalized PC compiler defines: require MS_WINDOWS or __BORLANDC__
or __WATCOMC__.  Add ALTSEP for PC filesystems.
1996-09-11 20:20:58 +00:00
Guido van Rossum a25e5e9ae9 PyMapping_DelItem[String] are actually macros. 1996-09-06 13:48:38 +00:00
Guido van Rossum ed227f0589 Correctly document PyNumber_Coerce. 1996-09-06 13:40:53 +00:00
Guido van Rossum ace527cbc2 Change comments/#ifdef structure for declaration for hypot(). 1996-08-29 18:12:36 +00:00
Guido van Rossum 2a516c8f2c Bump patchlevel (a bit early, but what the heck...) 1996-08-22 23:15:05 +00:00
Guido van Rossum 2ea0b06498 Add PYTHON_API_STRING, which is PYTHON_API_VERSION as a string literal.
Under Windows, add MS_DLL_ID and MS_DLL_VERSION_ID for Mark H.

Independent change: if Py_TRACE_REFS is defined, rename Py_InitModule4
so so linking with incompatible modules will create a link time error.

[Backing out of previous changes (also for modsupport.c) to test
the latter at runtime.]
1996-08-22 22:55:47 +00:00
Guido van Rossum 6cdc6f4146 Added PyObject_DelItem and PySequence_Del{Item,Slice}. 1996-08-21 17:41:54 +00:00
Guido van Rossum 7cf1fcf347 Always include config.h 1996-08-19 22:12:39 +00:00
Guido van Rossum 49c70a7a4d Added declaration for *PyMarshal_WriteObjectToString(). 1996-08-19 22:05:27 +00:00
Guido van Rossum 8b51d227f6 Add prototypes for c_sum() etc. 1996-08-19 22:04:54 +00:00
Guido van Rossum 0dfcf753ad Disable support for access statement 1996-08-12 22:00:53 +00:00
Guido van Rossum d86b38003d Added extern declarations for reference count admin debug functions. 1996-08-12 21:31:32 +00:00
Guido van Rossum 8b004d36ed Renamed to pyerrors.h 1996-08-09 23:15:18 +00:00
Guido van Rossum 0693dd232e Added tp_getattro, tp_setattro (Sjoerd) 1996-08-09 20:48:52 +00:00
Guido van Rossum 1d60614d42 Correctly use Py_PROTO, not obsolete PROTO. 1996-08-08 18:44:36 +00:00
Guido van Rossum 6f90e9862e Renamed errors. -> pyerrors.h (for Mac, where Errors.h is a system header). 1996-08-08 18:43:59 +00:00
Guido van Rossum 578cedde35 Typo: PySequence_Lenth -> PySequence_Length. 1996-08-08 18:43:10 +00:00
Guido van Rossum 9caf77a485 Put definition of _REENTRANT in config.h 1996-08-01 00:52:26 +00:00
Guido van Rossum 7a7eb37a10 patch level 1.4b2 1996-07-30 20:46:14 +00:00
Guido van Rossum 9de624d784 Added extern defn of hypot(). 1996-07-30 16:55:08 +00:00
Guido van Rossum e15d0dea07 Slice and ellipses interface 1996-07-30 16:42:30 +00:00
Guido van Rossum fdebf25705 Turn on CACHE_HASH, for 2% speedier dict lookups 1996-07-30 16:42:03 +00:00
Guido van Rossum db3b04104a Added BUILD_SLICE opcode. 1996-07-30 16:41:26 +00:00
Guido van Rossum ae8a99e3f5 Two bumps for the price of one (PYTHON_API_VERSION) 1996-07-30 16:41:02 +00:00
Guido van Rossum 26a70f6b32 Changes due to slice and ellipses grammar changes 1996-07-30 16:39:30 +00:00
Guido van Rossum 03eed47512 Added sliceobject.h. 1996-07-30 16:39:03 +00:00
Guido van Rossum 519b4339f1 renamed complex -> Py_complex 1996-07-21 02:24:22 +00:00
Guido van Rossum 5a84914803 Hacks for MS_COREDLL 1996-07-21 02:23:54 +00:00
Guido van Rossum bb864062f1 added new names for getprogramname, getargcargv 1996-07-21 02:23:24 +00:00
Guido van Rossum 4f4ce68085 Added prototype + doc for PySequence_Length() 1996-07-21 02:22:56 +00:00
Guido van Rossum 84fb82dda0 Patchlevel to 1.4 beta 1. 1996-06-26 18:29:09 +00:00
Guido van Rossum 04527a22c8 frozen_modules is now officially part of the API, remove _ from new name. 1996-06-17 17:05:38 +00:00
Guido van Rossum 4ee68d91c3 Add defs for struct _frozen and struct _frozen *PyImport_FrozenModules(); 1996-06-17 17:05:01 +00:00
Guido van Rossum 2e1beeac2e Add a hack for Solaris threads (why not, there are zillions of
hacks for Windows and DOS here already :-( ).
1996-06-11 18:40:02 +00:00
Guido van Rossum 9a97d6ce53 Added Py_GetPath (getpythonpath) 1996-05-28 22:27:07 +00:00
Guido van Rossum 5f1563cd93 rename more symbols 1996-05-24 21:11:58 +00:00
Guido van Rossum 652f108faf rename exported symbols with _Py_ prefix 1996-05-24 21:01:36 +00:00
Guido van Rossum 5048de2bc6 rename parser internal symbols with _Py_ prefix 1996-05-24 20:43:31 +00:00
Guido van Rossum e1cd6c175b don't use NDEBUG 1996-05-24 20:43:12 +00:00
Guido van Rossum 4b0538c472 Added PySys_SetPath. 1996-05-22 17:31:52 +00:00
Guido van Rossum b9d876020d Don't declare Py_FatalError.
Add Py_mport_Init and PyBuiltin_Init.
1996-05-22 17:30:12 +00:00
Guido van Rossum b221ac4f33 Define DL_IMPORT if necessary.
Include pydebug.h instead of declaring Py_FatalError.
1996-05-22 17:28:54 +00:00
Guido van Rossum dd197e91bf Added __WATCOMC__ as DOS compiler. 1996-05-22 17:26:25 +00:00
Guido van Rossum 39c2aae198 Added decl for PyImport_Init.
Changed decl for inittab to define struct _inittab first.
1996-05-22 17:25:28 +00:00
Guido van Rossum 2514ec7fa4 Used new names for PyBuiltin_GetDict, PyBuiltin_GetModule.
Added PyBuiltin_Init.
1996-05-22 17:24:06 +00:00
Guido van Rossum b422c24934 Added PyFile_decls for PyFile_WriteObject, PyFile_SoftSpace,
PyFile_WriteString.
1996-05-22 17:22:22 +00:00
Guido van Rossum 12669749f6 Debug related variable/function definitions go here. 1996-05-22 16:38:17 +00:00
Guido van Rossum 1799eb59da Non-trivial DL_IMPORT must now be defined in config.h.
Include <stdlib.h>.
Include several more Python header files, including new pydebug.h.
1996-05-22 16:37:29 +00:00
Guido van Rossum 60be1db9a9 Added some visual enhancements of debugging ifdefs.
Added PyNumber_Coerce decl.
1996-05-22 16:33:22 +00:00
Guido van Rossum 0578851964 Removed TRACE_REFS and REF_DEBUG b/w compat hacks -- they don't work.
Added defs for getbuiltindict, getbuiltinmod (bltinmodule.c).
1996-05-22 16:30:09 +00:00
Jack Jansen e708f4005d Include GUSI.h if compiling for mac with gusi-sockets 1996-02-14 16:04:39 +00:00
Jack Jansen b89f32e869 Added prototype for PySys_SetArgv 1996-01-22 14:56:29 +00:00
Guido van Rossum 5990592b71 added decl for PyComplex_AsCComplex 1996-01-12 00:55:11 +00:00
Guido van Rossum 3d1f09557b changes for ** (power) operator 1996-01-12 00:51:44 +00:00
Guido van Rossum b17d5dea48 changes for complex numbers 1996-01-12 00:50:33 +00:00
Guido van Rossum e0dbd590ea bump api version 1996-01-12 00:49:39 +00:00
Guido van Rossum 3ca2a95078 added complex and c object.h; get rid of Py_FatalError 1996-01-12 00:48:04 +00:00
Guido van Rossum f9fca9252f complex numbers a la Konrad Hinsen 1996-01-12 00:47:05 +00:00
Guido van Rossum 77654a7e5e opaque C object a la Jim Fulton 1996-01-12 00:44:03 +00:00
Guido van Rossum f36768eed5 set version to 1.3 1995-10-08 00:52:37 +00:00
Guido van Rossum 59c473be99 delete PyNothing_Check, which does not actually exist 1995-09-30 16:10:43 +00:00
Guido van Rossum 9d78d8d2fb spell TraceBack with capital B 1995-09-18 21:29:36 +00:00
Guido van Rossum 8ca687a68e use Py_PROTO macro 1995-09-18 21:20:02 +00:00
Guido van Rossum 23d7b4bbfd removed redundant C++ hack 1995-09-07 19:37:11 +00:00
Jack Jansen 54bc679d0a patchlevel set to 1.3b3 1995-09-01 11:46:27 +00:00
Guido van Rossum bebdc376c3 changes for keyword args to built-in functions and classes 1995-07-26 17:58:29 +00:00
Guido van Rossum 454674d5db add forgotten PyObject_SetAttrString 1995-07-26 17:53:29 +00:00
Guido van Rossum 884afd654a keyword arguments and faster function calls 1995-07-18 14:21:06 +00:00
Guido van Rossum 3c7807937e include abstract.h 1995-07-18 14:07:52 +00:00
Guido van Rossum a827537afa Generic Abstract Object Interface 1995-07-18 14:07:00 +00:00
Guido van Rossum 3b46a50d63 new opcodes RAISE_VARARGS, CALL_FUNCTION 1995-07-07 22:32:10 +00:00
Guido van Rossum 5bb73ed5e4 new grammar symbols arglist and argument 1995-07-07 22:31:40 +00:00
Jack Jansen f9480ce4d4 Changed ifdef __CFM68K__ to ifdef SYMANTEC__CFM68K__: CW has its own
unique set of ideosyncracies:-(
1995-06-27 13:12:09 +00:00
Guido van Rossum cf97469407 removed duplicate defs for None, False, True 1995-04-28 21:28:02 +00:00
Sjoerd Mullender 107c747009 DL_IMPORT needs an argument. 1995-04-25 11:53:24 +00:00
Jack Jansen 5dbc7231a0 DL_IMPORT macro was called in a funny way (and MW barfed on it) 1995-04-23 22:06:05 +00:00
Sjoerd Mullender 91e7a0bd2a Also count UNREF's as freeing an object (only relevant when
COUNT_ALLOCS is defined).
1995-04-06 13:47:48 +00:00
Guido van Rossum 8f7871eec3 finalizing 1.2 1995-04-05 12:24:52 +00:00
Guido van Rossum 6f9e433ab3 fix dusty debugging macros 1995-03-29 16:57:48 +00:00
Guido van Rossum 599de5ab9f addet SETTUPLEITEM and added cast to GETTUPLEITEM 1995-03-09 12:10:16 +00:00
Guido van Rossum 051ab123b4 make the type a parameter of the DL_IMPORT macro, for Borland C 1995-02-27 10:17:52 +00:00
Guido van Rossum 57836fe998 change in staticforward -- added statichere 1995-02-21 21:06:10 +00:00
Guido van Rossum 0acd4b6e82 changes for Mac CFM-68K 1995-02-18 14:50:12 +00:00
Guido van Rossum fe299f9408 add Py_FatalError 1995-02-17 15:01:39 +00:00
Guido van Rossum b13afdd6f4 added PyObject_IsTrue & PyCallable_Check to object interface 1995-02-17 15:01:21 +00:00
Jack Jansen 3cfc8bd841 exec_dode_object/PyImport_ExecCodeObject is now externally visible 1995-02-15 22:55:45 +00:00
Guido van Rossum f2038a3593 version 1.2-beta-3 1995-02-13 20:27:30 +00:00
Guido van Rossum b7d3d4e5d6 make newvarobj's size arg signed 1995-02-10 16:55:33 +00:00
Guido van Rossum 10f8efd87a add Py_CHARMASK 1995-02-10 16:51:02 +00:00
Guido van Rossum 9e89f0a5b3 added callable, removed run_pyc_file 1995-02-07 15:26:59 +00:00
Guido van Rossum 6978503235 added findmethodinchain and methodchain data types 1995-01-26 22:58:48 +00:00
Guido van Rossum 855d0b3602 corrected two unconverted names 1995-01-20 16:52:42 +00:00
Guido van Rossum 58e4a1e0cb last bits 1995-01-17 16:53:38 +00:00
Guido van Rossum 938178283c new names for lots of new functions 1995-01-17 16:01:01 +00:00
Guido van Rossum caa6380886 The great renaming, phase two: all header files have been updated to
use the new names exclusively, and the linker will see the new names.
Files that import "Python.h" also only see the new names.  Files that
import "allobjects.h" will continue to be able to use the old names,
due to the inclusion (in allobjects.h) of "rename2.h".
1995-01-12 11:45:45 +00:00
Guido van Rossum 6c1874fc2b changes for C++ (Tim MacKenzie) 1995-01-10 17:43:33 +00:00
Guido van Rossum 6135a87f2b __builtins__ mods (and sys_checkinterval for ceval.c) 1995-01-09 17:53:26 +00:00
Guido van Rossum 970a0a20b8 api version checking 1995-01-09 17:47:20 +00:00
Guido van Rossum a0d7a23398 sys.check_interval=x -> sys.setcheckinterval(x) 1995-01-09 17:46:13 +00:00
Guido van Rossum 5e56997969 initmodule2 -> initmodule3 (with doc string) 1995-01-07 11:51:27 +00:00
Guido van Rossum 3615aaf6c5 Changed since Grammar has changed 1995-01-07 10:33:27 +00:00
Guido van Rossum 7a01389bc7 add 5th arg to instancebinop 1995-01-07 10:33:05 +00:00
Guido van Rossum 0908bacfa5 added func_doc 1995-01-07 10:32:47 +00:00
Guido van Rossum 9dc8d0e0a3 added ml_doc and changed newmethodlist interface 1995-01-07 10:32:29 +00:00
Guido van Rossum 6fde390655 new tp_str and tp_doc members in type object 1995-01-07 10:32:04 +00:00
Guido van Rossum 5799b52008 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.
1995-01-04 19:06:22 +00:00
Guido van Rossum 66cb311fba Lots of small things, see ChangeLog 1994-12-30 15:33:50 +00:00
Jack Jansen 599f0d1c2c - Added ability to get at strings embedded in the struct
- For the mac, added ability to get at pascal-style strings
1994-12-14 13:04:05 +00:00
Jack Jansen 234fd7e4bb Use \n as PYTHONPATH delimiter on Mac (less likely to occur in
filenames than space).
1994-12-14 12:57:12 +00:00
Guido van Rossum f483846386 pl1.1.1; added newgetargs renaming 1994-11-10 22:29:04 +00:00
Guido van Rossum 5ebc0cad57 include stddef.h 1994-10-20 22:03:08 +00:00
Guido van Rossum 8780a44f2c Oops -- version number! 1994-10-06 17:00:05 +00:00
Guido van Rossum c5d92e1271 ceval.h: added Py_MakePendingCalls()
classobject.h: added instancebinop()
modsupport.h: added newgetargs()
rename1.h: removed Py_FPROTO
1994-09-28 15:44:39 +00:00
Guido van Rossum 956640880d pythonrun.h: added run_pyc_file
ceval.h: added Py_AddPendingCall
rest: modules using the new naming scheme must now include Python.h
1994-09-14 13:23:36 +00:00
Guido van Rossum c6cf1dd317 pythgonrun.h: added Py_AtExit().
rename1.h: add PyArg_GetInt.
1994-09-07 14:35:10 +00:00
Guido van Rossum 03a909628b Define cl_{get,set,del}attr members in classobject 1994-09-06 09:48:43 +00:00
Guido van Rossum d2002c79f0 Added PyArg_NoArgs(v) 1994-08-29 10:55:31 +00:00
Guido van Rossum ff18df0eb3 For THINK C 6.0 1994-08-29 10:55:19 +00:00
Guido van Rossum b4f066da49 Include/node.h: make some fields short to save space during
parsing
1994-08-23 13:37:43 +00:00
Guido van Rossum a715274421 No need to define THINK_C any more 1994-08-19 11:16:32 +00:00
Guido van Rossum e89bc75048 Changes for dynamic linking under NT 1994-08-18 16:18:13 +00:00
Guido van Rossum 8a38a6b99f Moved to Include and changed format to "<complete_version>" 1994-08-17 14:39:22 +00:00
Guido van Rossum e149fa2a1e * Objects/classobject.c, Include/classobject.h: added __getattr__
and __setattr__ support to override getattr(x, name) and
	setattr(x, name, value) for class instances.  This uses a special
	hack whereby the class is supposed to be static: the __getattr__
	and __setattr__ methods are looked up only once and saved in the
	instance structure for speed
1994-08-12 12:49:46 +00:00