summaryrefslogtreecommitdiffstats
path: root/Python
Commit message (Collapse)AuthorAgeFilesLines
* Reported by Klocwork #151.Neal Norwitz2006-07-171-2/+13
| | | | | | v2 can be NULL if exception2 is NULL. I don't think that condition can happen, but I'm not sure it can't either. Now the code will protect against either being NULL.
* Fix memory leak under some conditions.Neal Norwitz2006-07-161-7/+9
| | | | Reported by Klocwork, #98.
* Bug #1512814, Fix incorrect lineno's when code within a functionNeal Norwitz2006-07-161-5/+6
| | | | had more than 255 blank lines. Byte codes need to go first, line #s second.
* Accept long options "--help" and "--version".Georg Brandl2006-07-121-4/+27
|
* Actually change the MAGIC #. Create a new section for 2.5c1 and mention the ↵Neal Norwitz2006-07-121-1/+1
| | | | impact of changing the MAGIC #.
* Bug #1520864: unpacking singleton tuples in for loop (for x, in) work again.Neal Norwitz2006-07-122-2/+7
|
* Add missing Py_DECREFs.Thomas Heller2006-07-111-1/+2
|
* After approval from Anthony, merge the tim-current_framesTim Peters2006-07-102-3/+68
| | | | | | branch into the trunk. This adds a new sys._current_frames() function, which returns a dict mapping thread id to topmost thread stack frame.
* Bug #1512814, Fix incorrect lineno's when code at module scopeNeal Norwitz2006-07-101-1/+9
| | | | started after line 256.
* On 64 bit systems, int literals that use less than 64 bits are now intsNeal Norwitz2006-07-091-0/+11
| | | | rather than longs. This also fixes the test for eval(-sys.maxint - 1).
* Fix SF bug 1441486: bad unary minus folding in compiler.Neil Schemenauer2006-07-091-20/+53
|
* Fix AST compiler bug #1501934: incorrect LOAD/STORE_GLOBAL generation.Neil Schemenauer2006-07-092-3/+5
|
* Fix SF bug #1519018: 'as' is now validated properly in import statementsNeal Norwitz2006-07-081-1/+12
|
* Fix refleaks reported by Shane Hathaway in SF patch #1515361. This changeNeal Norwitz2006-07-061-2/+4
| | | | contains only the changes related to leaking the copy variable.
* Bug #1417699: Reject locale-specific decimal point in float()Martin v. Löwis2006-07-031-0/+7
| | | | and atof().
* Bug #1511381: codec_getstreamcodec() in codec.c is corrected toHye-Shik Chang2006-06-231-3/+6
| | | | | | omit a default "error" argument for NULL pointer. This allows the parser to take a codec from cjkcodecs again. (Reported by Taewook Kang and reviewed by Walter Doerwald)
* Patch #1454481: Make thread stack size runtime tunable.Andrew MacIntyre2006-06-134-5/+163
| | | | | | | | | | Heavily revised, comprising revisions: 46640 - original trunk revision (backed out in r46655) 46647 - markup fix (backed out in r46655) 46692:46918 merged from branch aimacintyre-sf1454481 branch tested on buildbots (Windows buildbots had problems not related to these changes).
* i and j are initialized below when used. No need to do it twiceNeal Norwitz2006-06-121-1/+1
|
* Get rid of f_restricted too. Doc the other 4 ints that were already removedNeal Norwitz2006-06-121-1/+1
| | | | at the NeedForSpeed sprint.
* Fix indentation of case and a Py_ssize_t issue.Neal Norwitz2006-06-121-2/+2
|
* Patch #1495999: Part two of Windows CE changes.Martin v. Löwis2006-06-106-3/+9
| | | | | | - update header checks, using autoconf - provide dummies for getenv, environ, and GetVersion - adjust MSC_VER check in socketmodule.c
* Argh. "integer" is a very confusing word ;)Georg Brandl2006-06-081-2/+2
| | | | | Actually, checking for INT_MAX and INT_MIN is correct since the format code explicitly handles a C "int".
* Bug #1502750: Fix getargs "i" format to use LONG_MIN and LONG_MAX for bounds ↵Georg Brandl2006-06-081-2/+2
| | | | checking.
* _PySys_Init(): It's rarely a good idea to size a buffer to theTim Peters2006-06-061-1/+1
| | | | | | | | exact maximum size someone guesses is needed. In this case, if we're really worried about extreme integers, then "cp%d" can actually need 14 bytes (2 for "cp" + 1 for \0 at the end + 11 for -(2**31-1)). So reserve 128 bytes instead -- nothing is actually saved by making a stack-local buffer tiny.
* Add 3 more bytes to a buffer to cover constants in string and null byte on ↵Brett Cannon2006-06-051-1/+1
| | | | | | top of 10 possible digits for an int. Closes bug #1501223.
* Revert revisions:Tim Peters2006-06-044-170/+4
| | | | | | | | | | | | | | | | 46640 Patch #1454481: Make thread stack size runtime tunable. 46647 Markup fix The first is causing many buildbots to fail test runs, and there are multiple causes with seemingly no immediate prospects for repairing them. See python-dev discussion. Note that a branch can (and should) be created for resolving these problems, like svn copy svn+ssh://svn.python.org/python/trunk -r46640 svn+ssh://svn.python.org/python/branches/NEW_BRANCH followed by merging rev 46647 to the new branch.
* Patch #1346214: correctly optimize away "if 0"-style stmtsGeorg Brandl2006-06-042-15/+49
| | | | (thanks to Neal for review)
* clean up function declarations to conform to PEP-7 style.Andrew MacIntyre2006-06-043-22/+44
|
* Patch #1454481: Make thread stack size runtime tunable.Andrew MacIntyre2006-06-044-4/+170
|
* [ 1497053 ] Let dicts propagate the exceptions in user __eq__().Armin Rigo2006-06-011-2/+13
| | | | [ 1456209 ] dictresize() vulnerability ( <- backport candidate ).
* Convert more modules to METH_VARARGS.Georg Brandl2006-05-291-5/+3
|
* Make use of METH_O and METH_NOARGS where possible.Georg Brandl2006-05-291-2/+2
| | | | Use Py_UnpackTuple instead of PyArg_ParseTuple where possible.
* Fix compiler warning.Georg Brandl2006-05-291-1/+1
|
* Handle PyMem_Malloc failure in pystrtod.c. Closes #1494671.Georg Brandl2006-05-291-0/+7
|
* Fix #1494605.Georg Brandl2006-05-291-1/+2
|
* Correct None refcount issue in Mac modules. (Are theyGeorg Brandl2006-05-281-1/+1
| | | | still used?)
* The empty string is a valid import path.Georg Brandl2006-05-281-2/+4
| | | | (fixes #1496539)
* PyErr_Display(), PyErr_WriteUnraisable(): Coverity found a cut-and-pasteTim Peters2006-05-282-18/+23
| | | | bug in both: `className` was referenced before being checked for NULL.
* Conversion of exceptions over from faked-up classes to new-style C types.Richard Jones2006-05-273-2056/+23
|
* needforspeed: backed out the Py_LOCAL-isation of ceval; the massive in-Fredrik Lundh2006-05-271-60/+55
| | | | | lining killed performance on certain Intel boxes, and the "aggressive" macro itself gives most of the benefits on others.
* Patch 1145039.Tim Peters2006-05-261-41/+56
| | | | | | | | | | | | | | | | | | | set_exc_info(), reset_exc_info(): By exploiting the likely (who knows?) invariant that when an exception's `type` is NULL, its `value` and `traceback` are also NULL, save some cycles in heavily-executed code. This is a "a kronar saved is a kronar earned" patch: the speedup isn't reliably measurable, but it obviously does reduce the operation count in the normal (no exception raised) path through PyEval_EvalFrameEx(). The tim-exc_sanity branch tries to push this harder, but is still blowing up (at least in part due to pre-existing subtle bugs that appear to have no other visible consequences!). Not a bugfix candidate.
* Replace Py_BuildValue("OO") by PyTuple_Pack.Georg Brandl2006-05-262-4/+4
|
* Need for speed: Patch #921466 : sys.path_importer_cache is now used to cache ↵Georg Brandl2006-05-261-2/+30
| | | | | | | | | | valid and invalid file paths for the built-in import machinery which leads to fewer open calls on startup. Also fix issue with PEP 302 style import hooks which lead to more open() calls than necessary.
* Py_LOCAL shouldn't be used for data; it works for some .NET 2003 compilers,Fredrik Lundh2006-05-261-1/+1
| | | | but Trent's copy thinks that it's an anachronism...
* needforspeed: added PY_LOCAL_AGGRESSIVE macro to enable "aggressive"Fredrik Lundh2006-05-261-15/+23
| | | | LOCAL inlining; also added some missing whitespace
* needforspeed: added Py_LOCAL macro, based on the LOCAL macro usedFredrik Lundh2006-05-261-53/+53
| | | | | for SRE and others. applied Py_LOCAL to relevant portion of ceval, which gives a 1-2% speedup on my machine. ymmv.
* Swap out bare malloc()/free() use for PyMem_MALLOC()/PyMem_FREE() .Brett Cannon2006-05-251-2/+2
|
* Replace PyObject_CallFunction calls with only object argsGeorg Brandl2006-05-252-4/+4
| | | | with PyObject_CallFunctionObjArgs, which is 30% faster.
* A new table to help string->integer conversion was added yesterday toTim Peters2006-05-251-30/+2
| | | | | | both mystrtoul.c and longobject.c. Share the table instead. Also cut its size by 64 entries (they had been used for an inscrutable trick originally, but the code no longer tries to use that trick).
* Update graminit.c for the fix for #1488915, Multiple dots in relative importThomas Wouters2006-05-251-20/+15
| | | | statement raise SyntaxError, and add testcase.