summaryrefslogtreecommitdiff
path: root/Python/ast.c
Commit message (Collapse)AuthorAgeFilesLines
* fix indentationBenjamin Peterson2012-01-161-5/+5
|
* break out switch at correct placeBenjamin Peterson2012-01-161-1/+1
|
* only finish error if one occurredBenjamin Peterson2012-01-161-1/+2
|
* move LINENO define to where it actually belongsBenjamin Peterson2012-01-161-4/+0
|
* streamline normalizer identification a bitBenjamin Peterson2012-01-161-25/+55
|
* fix spellingBenjamin Peterson2012-01-161-1/+1
|
* invert condition (head bang)Benjamin Peterson2012-01-161-1/+1
|
* fix possible refleaksBenjamin Peterson2012-01-161-2/+4
|
* use helpful PyUnicode_IS_ASCII macroBenjamin Peterson2012-01-161-1/+1
|
* PyUnicode_DecodeUTF8 will always return a ready stringBenjamin Peterson2012-01-161-1/+2
|
* rewrite such that this actually makes senseBenjamin Peterson2012-01-161-1/+1
|
* make YieldFrom its own distinct from Yield (closes #13780)Benjamin Peterson2012-01-141-1/+7
|
* Implement PEP 380 - 'yield from' (closes #11682)Nick Coghlan2012-01-131-5/+16
|
* Issue #13748: Raw bytes literals can now be written with the `rb` prefix as ↵Antoine Pitrou2012-01-121-7/+12
| | | | well as `br`.
* Rename _Py_identifier to _Py_IDENTIFIER.Martin v. Löwis2011-10-141-1/+1
|
* Add API for static strings, primarily good for identifiers.Martin v. Löwis2011-10-091-1/+2
| | | | Thanks to Konrad Schöbel and Jasper Schulz for helping with the mass-editing.
* Implement PEP 393.Martin v. Löwis2011-09-281-37/+24
|
* add a AST validator (closes #12575)Benjamin Peterson2011-08-091-4/+482
|
* merge 3.2Benjamin Peterson2011-06-201-1/+1
|\
| * fix indentationBenjamin Peterson2011-06-201-1/+1
| |
* | unify TryExcept and TryFinally (closes #12199)Benjamin Peterson2011-05-291-18/+4
| |
* | reflect with statements with multiple items in the AST (closes #12106)Benjamin Peterson2011-05-271-27/+16
| |
* | merge 3.2Benjamin Peterson2011-04-121-0/+1
|\ \ | |/
| * merge 3.1Benjamin Peterson2011-04-121-0/+1
| |\
| | * make assigning to a bytes literal a syntax error (closes #11506)Benjamin Peterson2011-04-121-0/+1
| | |
| | * Recorded merge of revisions 85569-85570 via svnmerge fromVictor Stinner2010-10-191-1/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r85569 | victor.stinner | 2010-10-16 15:14:10 +0200 (sam., 16 oct. 2010) | 4 lines Issue #9713, #10114: Parser functions (eg. PyParser_ASTFromFile) expects filenames encoded to the filesystem encoding with surrogateescape error handler (to support undecodable bytes), instead of UTF-8 in strict mode. ........ r85570 | victor.stinner | 2010-10-16 15:42:53 +0200 (sam., 16 oct. 2010) | 4 lines Fix ast_error_finish() and err_input(): filename can be NULL Fix my previous commit (r85569). ........
| | * Merged revisions 84214 via svnmerge fromAmaury Forgeot d'Arc2010-08-191-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r84214 | amaury.forgeotdarc | 2010-08-19 23:32:38 +0200 (jeu., 19 août 2010) | 3 lines Add tests for r84209 (crashes in the Ast builder) Also remove one tab, and move a check closer to the possible failure. ........
| | * Merged revisions 84209 via svnmerge fromAmaury Forgeot d'Arc2010-08-191-25/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r84209 | amaury.forgeotdarc | 2010-08-19 19:43:15 +0200 (jeu., 19 août 2010) | 5 lines Check the return values for all functions returning an ast node. Failure to do it may result in strange error messages or even crashes, in admittedly convoluted cases that are normally syntax errors, like: def f(*xx, __debug__): pass ........
| | * Revert r82044, since it changed the semantics of negated imaginary literals.Mark Dickinson2010-06-301-0/+26
| | | | | | | | | | | | | | | Before r82044, '-7j' became complex(0.0, -7.0); afterwards it was complex(-0.0, -7.0). See issue 9011.
| | * Merged revisions 82043 via svnmerge fromMark Dickinson2010-06-171-26/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r82043 | mark.dickinson | 2010-06-17 13:33:22 +0100 (Thu, 17 Jun 2010) | 6 lines Issue #9011: Remove buggy and unnecessary ST->AST compilation code dealing with unary minus applied to a constant. The removed code was mutating the ST, causing a second compilation to fail. (The peephole optimizer already takes care of optimizing this case, so there's no lost optimization opportunity here.) ........
| | * Recorded merge of revisions 81032 via svnmerge fromAntoine Pitrou2010-05-091-94/+94
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ................ r81032 | antoine.pitrou | 2010-05-09 17:52:27 +0200 (dim., 09 mai 2010) | 9 lines Recorded merge of revisions 81029 via svnmerge from svn+ssh://pythondev@svn.python.org/python/trunk ........ r81029 | antoine.pitrou | 2010-05-09 16:46:46 +0200 (dim., 09 mai 2010) | 3 lines Untabify C files. Will watch buildbots. ........ ................
| | * Merged revisions 75928 via svnmerge fromBenjamin Peterson2009-10-291-9/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r75928 | benjamin.peterson | 2009-10-28 16:59:39 -0500 (Wed, 28 Oct 2009) | 5 lines in wide builds, avoid storing high unicode characters from source code with surrogates This is accomplished by decoding with utf-32 instead of utf-16 on all builds. The patch is by Adam Olsen. ........
| | * Merged revisions 75224 via svnmerge fromBenjamin Peterson2009-10-031-0/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ................ r75224 | benjamin.peterson | 2009-10-03 15:27:13 -0500 (Sat, 03 Oct 2009) | 9 lines Merged revisions 75223 via svnmerge from svn+ssh://pythondev@svn.python.org/python/trunk ........ r75223 | benjamin.peterson | 2009-10-03 15:23:24 -0500 (Sat, 03 Oct 2009) | 1 line #7050 fix a SystemError when using tuple unpacking and augmented assignment ........ ................
* | | Issue #8914: fix various warnings from the Clang static analyzer v254.Brett Cannon2011-02-221-1/+0
|/ /
* | Remove redundant includes of headers that are already included by Python.h.Georg Brandl2010-11-301-1/+0
| |
* | Fix ast_error_finish() and err_input(): filename can be NULLVictor Stinner2010-10-161-1/+6
| | | | | | | | Fix my previous commit (r85569).
* | Issue #9713, #10114: Parser functions (eg. PyParser_ASTFromFile) expectsVictor Stinner2010-10-161-1/+6
| | | | | | | | | | filenames encoded to the filesystem encoding with surrogateescape error handler (to support undecodable bytes), instead of UTF-8 in strict mode.
* | add column offset to all syntax errorsBenjamin Peterson2010-09-201-3/+8
| |
* | Add tests for r84209 (crashes in the Ast builder)Amaury Forgeot d'Arc2010-08-191-3/+3
| | | | | | | | Also remove one tab, and move a check closer to the possible failure.
* | Check the return values for all functions returning an ast node.Amaury Forgeot d'Arc2010-08-191-26/+27
| | | | | | | | | | | | Failure to do it may result in strange error messages or even crashes, in admittedly convoluted cases that are normally syntax errors, like: def f(*xx, __debug__): pass
* | Issue #9011: Remove buggy and unnecessary ST->AST compilation codeMark Dickinson2010-06-171-26/+0
| | | | | | | | | | | | | | dealing with unary minus applied to a constant. The removed code was mutating the ST, causing a second compilation to fail. (The peephole optimizer already takes care of optimizing this case, so there's no lost optimization opportunity here.)
* | Recorded merge of revisions 81029 via svnmerge fromAntoine Pitrou2010-05-091-95/+95
| | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r81029 | antoine.pitrou | 2010-05-09 16:46:46 +0200 (dim., 09 mai 2010) | 3 lines Untabify C files. Will watch buildbots. ........
* | in wide builds, avoid storing high unicode characters from source code with ↵Benjamin Peterson2009-10-281-9/+14
| | | | | | | | | | | | | | surrogates This is accomplished by decoding with utf-32 instead of utf-16 on all builds. The patch is by Adam Olsen.
* | Issue 7147 - remove ability to attempt to build Python without complex ↵Skip Montanaro2009-10-181-6/+0
| | | | | | | | number support (was broken anyway)
* | Merged revisions 75223 via svnmerge fromBenjamin Peterson2009-10-031-0/+13
| | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r75223 | benjamin.peterson | 2009-10-03 15:23:24 -0500 (Sat, 03 Oct 2009) | 1 line #7050 fix a SystemError when using tuple unpacking and augmented assignment ........
* | star_expr now always has two nodesBenjamin Peterson2009-09-271-3/+1
| |
* | fix an ambiguity in the grammar from the implementation of extended unpackingBenjamin Peterson2009-09-271-13/+14
| | | | | | | | | | | | | | (one which was strangely "resolved" by pgen) This also kills the unused testlist1 rule and fixes parse tree validation of extended unpacking.
* | Merged revisions 74464 via svnmerge fromBenjamin Peterson2009-09-111-11/+10
| | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r74464 | benjamin.peterson | 2009-08-15 17:59:21 -0500 (Sat, 15 Aug 2009) | 4 lines better col_offsets for "for" statements with tuple unpacking #6704 Patch from Frank Wierzbicki. ........
* | In most cases, the parser will protect True, False, and None from being ↵Benjamin Peterson2009-06-281-13/+38
| | | | | | | | | | | | assign to. We must check for __debug__ in all cases.
* | Merged revisions ↵Benjamin Peterson2009-06-281-35/+47
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 73376,73393,73398,73400,73404-73405,73409,73419-73421,73432,73457,73460,73485-73486,73488-73489,73501-73502,73513-73514 via svnmerge from svn+ssh://pythondev@svn.python.org/python/trunk ........ r73376 | benjamin.peterson | 2009-06-11 17:29:23 -0500 (Thu, 11 Jun 2009) | 1 line remove check for case handled in sub-function ........ r73393 | alexandre.vassalotti | 2009-06-12 13:56:57 -0500 (Fri, 12 Jun 2009) | 2 lines Clear reference to the static PyExc_RecursionErrorInst in _PyExc_Fini. ........ r73398 | alexandre.vassalotti | 2009-06-12 15:57:12 -0500 (Fri, 12 Jun 2009) | 3 lines Add const qualifier to PyErr_SetFromErrnoWithFilename and to PyErr_SetFromErrnoWithUnicodeFilename. ........ r73400 | alexandre.vassalotti | 2009-06-12 16:43:47 -0500 (Fri, 12 Jun 2009) | 2 lines Delete outdated make file for building the parser with MSVC 6. ........ r73404 | benjamin.peterson | 2009-06-12 20:40:00 -0500 (Fri, 12 Jun 2009) | 1 line keep the slice.step field as NULL if no step expression is given ........ r73405 | benjamin.peterson | 2009-06-12 22:46:30 -0500 (Fri, 12 Jun 2009) | 1 line prevent import statements from assigning to None ........ r73409 | benjamin.peterson | 2009-06-13 08:06:21 -0500 (Sat, 13 Jun 2009) | 1 line allow importing from a module named None if it has an 'as' clause ........ r73419 | benjamin.peterson | 2009-06-13 11:19:19 -0500 (Sat, 13 Jun 2009) | 1 line set Print.values to NULL if there are no values ........ r73420 | benjamin.peterson | 2009-06-13 12:08:53 -0500 (Sat, 13 Jun 2009) | 1 line give a better error message when deleting () ........ r73421 | benjamin.peterson | 2009-06-13 15:23:33 -0500 (Sat, 13 Jun 2009) | 1 line when no module is given in a 'from' relative import, make ImportFrom.module NULL ........ r73432 | amaury.forgeotdarc | 2009-06-14 16:20:40 -0500 (Sun, 14 Jun 2009) | 3 lines #6227: Because of a wrong indentation, the test was not testing what it should. Ensure that the snippet in doctest_aliases actually contains aliases. ........ r73457 | benjamin.peterson | 2009-06-16 18:13:09 -0500 (Tue, 16 Jun 2009) | 1 line add underscores ........ r73460 | benjamin.peterson | 2009-06-16 22:23:04 -0500 (Tue, 16 Jun 2009) | 1 line remove unused 'encoding' member from the compiler struct ........ r73485 | benjamin.peterson | 2009-06-19 17:07:47 -0500 (Fri, 19 Jun 2009) | 1 line remove duplicate test ........ r73486 | benjamin.peterson | 2009-06-19 17:09:17 -0500 (Fri, 19 Jun 2009) | 1 line add missing assertion #6313 ........ r73488 | benjamin.peterson | 2009-06-19 17:16:28 -0500 (Fri, 19 Jun 2009) | 1 line show that this one isn't used ........ r73489 | benjamin.peterson | 2009-06-19 17:21:12 -0500 (Fri, 19 Jun 2009) | 1 line use closures ........ r73501 | benjamin.peterson | 2009-06-21 18:01:07 -0500 (Sun, 21 Jun 2009) | 1 line don't need to add the name 'lambda' as assigned ........ r73502 | benjamin.peterson | 2009-06-21 18:03:36 -0500 (Sun, 21 Jun 2009) | 1 line remove tmpname support since it's no longer used ........ r73513 | benjamin.peterson | 2009-06-22 20:18:57 -0500 (Mon, 22 Jun 2009) | 1 line fix grammar ........ r73514 | benjamin.peterson | 2009-06-22 22:01:56 -0500 (Mon, 22 Jun 2009) | 1 line remove some unused symtable constants ........