summaryrefslogtreecommitdiffstats
path: root/Python
Commit message (Collapse)AuthorAgeFilesLines
* Make AST nodes pickleable.Georg Brandl2008-03-301-2/+27
|
* Fix error message -- "expects either 0 or 0 arguments"Georg Brandl2008-03-301-2/+4
|
* Make _fields attr for no fields consistent with _attributes attr.Georg Brandl2008-03-301-8/+3
|
* #2505: allow easier creation of AST nodes.Georg Brandl2008-03-301-22/+113
|
* Patch #2511: Give the "excepthandler" AST item proper attributes by making ↵Georg Brandl2008-03-304-94/+122
| | | | it a Sum.
* Properly check for consistency with the third argument ofGeorg Brandl2008-03-292-20/+27
| | | | compile() when compiling an AST node.
* Fix a reference leak found by Georg, when compiling a class nested in ↵Amaury Forgeot d'Arc2008-03-281-0/+1
| | | | | | | | another class. Now "regrtest.py -R:: test_compile" is satisfied. Will backport.
* Silence a compilation warningAmaury Forgeot d'Arc2008-03-281-1/+1
|
* Patch #1810 by Thomas Lee, reviewed by myself:Georg Brandl2008-03-283-30/+2919
| | | | | allow compiling Python AST objects into code objects in compile().
* Revert r61969 which added casts to Py_CHARMASK to avoid compiler warnings.Neal Norwitz2008-03-281-8/+8
| | | | | | Rather than sprinkle casts throughout the code, change Py_CHARMASK to always cast it's result to an unsigned char. This should ensure we do the right thing when accessing an array with the result.
* Build bots are working again - removing the hackChristian Heimes2008-03-271-1/+1
|
* Quick 'n dirty hack: Increase the magic by 2 to force a rebuild of pyc/pyo ↵Christian Heimes2008-03-271-1/+1
| | | | files on the build bots
* Fix warnings about using char as an array subscript. This is not portableNeal Norwitz2008-03-271-8/+8
| | | | since char is signed on some platforms and unsigned on others.
* C89 compliance: Microsoft compilers want variable declarations at the topAmaury Forgeot d'Arc2008-03-261-4/+2
|
* Initialize PyCompilerFlags cf_flags with 0Christian Heimes2008-03-262-0/+4
|
* Patch #2477: Added from __future__ import unicode_literalsChristian Heimes2008-03-264-19/+41
| | | | The new PyParser_*Ex() functions are based on Neal's suggestion and initial patch. The new __future__ feature makes all '' and r'' unicode strings. b'' and br'' stay (byte) strings.
* Merged revisions ↵Christian Heimes2008-03-262-1/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 61750,61752,61754,61756,61760,61763,61768,61772,61775,61805,61809,61812,61819,61917,61920,61930,61933-61934 via svnmerge from svn+ssh://pythondev@svn.python.org/python/branches/trunk-bytearray ........ r61750 | christian.heimes | 2008-03-22 20:47:44 +0100 (Sat, 22 Mar 2008) | 1 line Copied files from py3k w/o modifications ........ r61752 | christian.heimes | 2008-03-22 20:53:20 +0100 (Sat, 22 Mar 2008) | 7 lines Take One * Added initialization code, warnings, flags etc. to the appropriate places * Added new buffer interface to string type * Modified tests * Modified Makefile.pre.in to compile the new files * Added bytesobject.c to Python.h ........ r61754 | christian.heimes | 2008-03-22 21:22:19 +0100 (Sat, 22 Mar 2008) | 2 lines Disabled bytearray.extend for now since it causes an infinite recursion Fixed serveral unit tests ........ r61756 | christian.heimes | 2008-03-22 21:43:38 +0100 (Sat, 22 Mar 2008) | 5 lines Added PyBytes support to several places: str + bytearray ord(bytearray) bytearray(str, encoding) ........ r61760 | christian.heimes | 2008-03-22 21:56:32 +0100 (Sat, 22 Mar 2008) | 1 line Fixed more unit tests related to type('') is not unicode ........ r61763 | christian.heimes | 2008-03-22 22:20:28 +0100 (Sat, 22 Mar 2008) | 2 lines Fixed more unit tests Fixed bytearray.extend ........ r61768 | christian.heimes | 2008-03-22 22:40:50 +0100 (Sat, 22 Mar 2008) | 1 line Implemented old buffer interface for bytearray ........ r61772 | christian.heimes | 2008-03-22 23:24:52 +0100 (Sat, 22 Mar 2008) | 1 line Added backport of the io module ........ r61775 | christian.heimes | 2008-03-23 03:50:49 +0100 (Sun, 23 Mar 2008) | 1 line Fix str assignement to bytearray. Assignment of a str of size 1 is interpreted as a single byte ........ r61805 | christian.heimes | 2008-03-23 19:33:48 +0100 (Sun, 23 Mar 2008) | 3 lines Fixed more tests Fixed bytearray() comparsion with unicode() Fixed iterator assignment of bytearray ........ r61809 | christian.heimes | 2008-03-23 21:02:21 +0100 (Sun, 23 Mar 2008) | 2 lines str(bytesarray()) now returns the bytes and not the representation of the bytearray object Enabled and fixed more unit tests ........ r61812 | christian.heimes | 2008-03-23 21:53:08 +0100 (Sun, 23 Mar 2008) | 3 lines Clear error PyNumber_AsSsize_t() fails Use CHARMASK for ob_svall access disabled a test with memoryview again ........ r61819 | christian.heimes | 2008-03-23 23:05:57 +0100 (Sun, 23 Mar 2008) | 1 line Untested updates to the PCBuild directory ........ r61917 | christian.heimes | 2008-03-26 00:57:06 +0100 (Wed, 26 Mar 2008) | 1 line The type system of Python 2.6 has subtle differences to 3.0's. I've removed the Py_TPFLAGS_BASETYPE flags from bytearray for now. bytearray can't be subclasses until the issues with bytearray subclasses are fixed. ........ r61920 | christian.heimes | 2008-03-26 01:44:08 +0100 (Wed, 26 Mar 2008) | 2 lines Disabled last failing test I don't understand what the test is testing and how it suppose to work. Ka-Ping, please check it out. ........ r61930 | christian.heimes | 2008-03-26 12:46:18 +0100 (Wed, 26 Mar 2008) | 1 line Re-enabled bytes warning code ........ r61933 | christian.heimes | 2008-03-26 13:20:46 +0100 (Wed, 26 Mar 2008) | 1 line Fixed a bug in the new buffer protocol. The buffer slots weren't copied into a subclass. ........ r61934 | christian.heimes | 2008-03-26 13:25:09 +0100 (Wed, 26 Mar 2008) | 1 line Re-enabled bytearray subclassing - all tests are passing. ........
* Make Py3k warnings consistent w.r.t. punctuation; also respect theGeorg Brandl2008-03-254-10/+14
| | | | EOL 80 limit and supply more alternatives in warning messages.
* Try to fix a bunch of compiler warnings on Win64.Neal Norwitz2008-03-251-2/+2
|
* Added quick hack for bzrChristian Heimes2008-03-241-2/+2
|
* Added quick hack for bzrChristian Heimes2008-03-241-1/+8
|
* Remove compiler warnings (on Alpha at least) about using chars asNeal Norwitz2008-03-231-5/+6
| | | | | array subscripts. Using chars are dangerous b/c they are signed on some platforms and unsigned on others.
* #2358: add py3k warning to sys.exc_clear().Georg Brandl2008-03-211-1/+9
|
* The filter() function does support a None argument in Py3.0.Raymond Hettinger2008-03-191-7/+0
|
* Issue #2400: Allow relative imports to "import *".Martin v. Löwis2008-03-191-4/+0
|
* Backport of the print function, using a __future__ import.Eric Smith2008-03-183-4/+80
| | | | | | | | This work is substantially Anthony Baxter's, from issue 1633807. I just freshened it, made a few minor tweaks, and added the test cases. I also created issue 2412, which is to check for 2to3's behavior with the print function. I also added myself to ACKS.
* Added a warning when -3 is enabled and None is passed to filter as the first ↵David Wolever2008-03-181-0/+7
| | | | argument.
* Finish backporting new buffer API to Python 2.6. Left to do: memoryview ↵Travis E. Oliphant2008-03-181-0/+1
| | | | object and structmodule. But, these need to be finished in Python 3.0 first. No objects support the new buffer API in Python 2.6 as of yet, and except for the memoryview object, I don't think they will.
* Issue #2341: Add a Py3k warning when raising an exception that doesn'tGuido van Rossum2008-03-181-0/+9
| | | | derive from BaseException.
* Remove our implementation of memmove() and strerror(); both are in the C89Brett Cannon2008-03-182-44/+0
| | | | standard library.
* Clean up the Py3k warnings for non-BaseException-subclasses a bit. WeGuido van Rossum2008-03-181-4/+6
| | | | | now don't warn for some corner cases that deserve a warning, rather than warning double or incorrectly for some other corner cases.
* - Issue #2371: Add a Py3k warning when catching an exception thatGuido van Rossum2008-03-181-0/+27
| | | | doesn't derive from BaseException.
* Finished backporting PEP 3127, Integer Literal Support and Syntax.Eric Smith2008-03-171-6/+54
| | | | | | | | Added 0b and 0o literals to tokenizer. Modified PyOS_strtoul to support 0b and 0o inputs. Modified PyLong_FromString to support guessing 0b and 0o inputs. Renamed test_hexoct.py to test_int_literal.py and added binary tests. Added upper and lower case 0b, 0O, and 0X tests to test_int_literal.py
* Reformated lines > 79 chars.Eric Smith2008-03-171-8/+12
| | | | Deleted unused macro ISXDIGIT.
* Issue 2264: empty float presentation type needs to have at least one digit ↵Eric Smith2008-03-171-17/+61
| | | | | | | | | past the decimal point. Added "Z" format_char to PyOS_ascii_formatd to support empty float presentation type. Renamed buf_size in PyOS_ascii_formatd to more accurately reflect it's meaning. Modified format.__float__ to use the new "Z" format as the default. Added test cases.
* Handle memory allocation failure. Found by Adam OlsenNeal Norwitz2008-03-151-2/+3
|
* Add a warning for code like:Neal Norwitz2008-03-151-0/+8
| | | | | | | | | | assert (0, 'message') An empty tuple does not create a warning. While questionable usage: assert (), 'message' should not display a warning. Tested manually. The warning message could be improved. Feel free to update it.
* Speed up with statements by storing the __exit__ method on the stack instead ↵Nick Coghlan2008-03-073-39/+58
| | | | of in a temp variable (bumps the magic number for pyc files)
* Issue#2238: some syntax errors from *args or **kwargs expressionsAmaury Forgeot d'Arc2008-03-051-0/+4
| | | | | | | | | | | | | | would give bogus error messages, because of untested exceptions:: >>> f(**g(1=2)) XXX undetected error Traceback (most recent call last): File "<stdin>", line 1, in <module> TypeError: 'int' object is not iterable instead of the expected SyntaxError: keyword can't be an expression Will backport.
* compile.c always emits END_FINALLY after WITH_CLEANUP, so predict that inJeffrey Yasskin2008-03-031-0/+2
| | | | ceval.c. This is worth about a .03-.04us speedup on a simple with block.
* More copyright year and version number bumpsv2.6a1Barry Warsaw2008-03-011-1/+1
|
* Patch #1691070 from Roger Upole: Speed up PyArg_ParseTupleAndKeywords() and ↵Christian Heimes2008-02-261-154/+109
| | | | | | improve error msg My tests don't show the promised speed up of 10%. The code is as fast as the old code for simple cases and slightly faster for complex cases with several of args and kwargs. But the patch simplifies the code, too.
* Whitespace normalizationNeal Norwitz2008-02-261-6/+6
|
* Fix indentationNeal Norwitz2008-02-252-2/+2
|
* Add a little info to the 3k deprecation warnings about what to use instead.Neal Norwitz2008-02-241-4/+4
| | | | Suggested by Raymond Hettinger.
* map(None, ...) is not supported in 3.0.Neal Norwitz2008-02-241-3/+9
|
* MS Windows doesn't have mode_t but stat.st_mode is defined as unsigned short.Christian Heimes2008-02-231-0/+5
|
* Issue #2051 and patch from Alexander Belopolsky:Christian Heimes2008-02-232-15/+16
| | | | Permission for pyc and pyo files are inherited from the py file.
* Removed duplicate Py_CHARMASK define. It's already defined in Python.h.Eric Smith2008-02-231-8/+0
|
* Patch #1759: Backport of PEP 3129 class decoratorsChristian Heimes2008-02-235-1202/+1260
| | | | with some help from Georg