summaryrefslogtreecommitdiffstats
path: root/Parser/asdl_c.py
Commit message (Collapse)AuthorAgeFilesLines
* Use file.write instead of print to make it easier to merge with 3k.Neal Norwitz2008-03-311-12/+13
|
* 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-8/+100
|
* Properly check for consistency with the third argument ofGeorg Brandl2008-03-291-5/+12
| | | | compile() when compiling an AST node.
* Silence compiler warning at the source.Georg Brandl2008-03-281-1/+1
|
* Patch #1810 by Thomas Lee, reviewed by myself:Georg Brandl2008-03-281-2/+268
| | | | | allow compiling Python AST objects into code objects in compile().
* Patch #2167 from calvin: Remove unused importsChristian Heimes2008-02-231-1/+1
|
* Fix a couple of problems in generating the AST code:Neal Norwitz2007-02-261-5/+3
| | | | | | * use %r instead of backticks since backticks are going away in Py3k * PyArena_Malloc() already sets PyErr_NoMemory so we don't need to do it again * the signature for ast2obj_int incorrectly used a bool, rather than a long
* Modify Parser/asdl_c.py so that the __version__ number for Python/Python-ast.cBrett Cannon2007-02-121-2/+19
| | | | | | is specified at the top of the file. Also add a note that Python/Python-ast.c needs to be committed separately after a change to the AST grammar to capture the revision number of the change (which is what __version__ is set to).
* Prefix AST symbols with _Py_. Fixes #1637022.Martin v. Löwis2007-01-191-1/+6
| | | | Will backport.
* Patch #1355883: Build Python-ast.c and Python-ast.hMartin v. Löwis2006-04-141-30/+30
| | | | independently. Fixes #1355883.
* Introduce asdl_int_seq, to hold cmpop_ty.Martin v. Löwis2006-04-131-3/+9
|
* Make _kind types global for C++ compilation.Martin v. Löwis2006-04-111-3/+5
| | | | Explicitly cast void* to int to cmpop_ty.
* Make path calculation platform independentJeremy Hylton2006-04-041-1/+1
|
* Add lineno, col_offset to excephandler to enable future fix forJeremy Hylton2006-04-041-1/+1
| | | | | | | | | | | | | | | tracing/line number table in except blocks. Reflow long lines introduced by col_offset changes. Update test_ast to handle new fields in excepthandler. As note in Python.asdl says, we might want to rethink how attributes are handled. Perhaps they should be the same as other fields, with the primary difference being how they are defined for all types within a sum. Also fix asdl_c so that constructors with int fields don't fail when passed a zero value.
* * Fix a refleak of *_attributes.Neal Norwitz2006-04-031-5/+7
| | | | | | * Cleanup formatting a bit (add spaces). * Move static var initialized inside init_types() since that's the only place it's used.
* Fix memory leak on attributes.Martin v. Löwis2006-03-021-1/+3
|
* Don't pollute namespace as bad as before. All the types are static now.Neal Norwitz2006-02-281-7/+7
|
* Whitespace normalization.Tim Peters2006-02-281-13/+13
|
* Generate return statement.Martin v. Löwis2006-02-281-0/+1
|
* Add generation of the version.Martin v. Löwis2006-02-281-1/+2
|
* Add support for version field on ModulesMartin v. Löwis2006-02-281-0/+1
|
* Create _ast module.Martin v. Löwis2006-02-271-191/+86
| | | | Cleanup Python-ast.c generation.
* Avoid reinitializing the types twice.Martin v. Löwis2006-02-271-0/+1
|
* Stop generating empty arrays.Martin v. Löwis2006-02-261-12/+22
|
* Fix iterating over cmpop_ty lists.Martin v. Löwis2006-02-261-5/+13
|
* Generate code to recursively copy an AST intoMartin v. Löwis2006-02-261-59/+206
| | | | a tree of Python objects. Expose this through compile().
* Whitespace normalization.Tim Peters2005-12-251-50/+50
|
* Merge from ast-arena. This reduces the code in Python/ast.c by ~300 lines,Neal Norwitz2005-12-171-5/+10
| | | | simplifies a lot of error handling code, and fixes many memory leaks.
* When regenerating files like Python-ast.h, take care that the generatedArmin Rigo2005-12-141-3/+2
| | | | | | | comment based on 'sys.args[0]' does not depend on the path. For Python builds from a remote directory ("/path/to/configure; make") the previous logic used to include the "/path/to" portion in Python-ast.h. Then svn would consider this file to be locally modified.
* SF #1373150, diffs in working copy after a buildNeal Norwitz2005-12-111-1/+5
| | | | | | | | Strip off leading dots and slash so the generated files are the same regardless of whether you configure in the checkout directory or build. If anyone configures in a different directory, we might want a cleaner approach using os.path.*(). Hopefully this is good enough.
* Whoops, checkin consistent versions of *all* files to stop pollutingNeal Norwitz2005-11-131-6/+80
| | | | a bunch of names
* Prevent name pollution by making lots of internal functions static.Neal Norwitz2005-11-131-4/+4
|
* Use PyErr_NoMemory() instead of rolling our own.Neal Norwitz2005-10-231-7/+5
| | | | Get rid of "int i" unused warnings from Python-ast.c which we are generating.
* Merge ast-branch to headJeremy Hylton2005-10-201-0/+621
This change implements a new bytecode compiler, based on a transformation of the parse tree to an abstract syntax defined in Parser/Python.asdl. The compiler implementation is not complete, but it is in stable enough shape to run the entire test suite excepting two disabled tests.