summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_compiler.py
Commit message (Collapse)AuthorAgeFilesLines
* Deprecate the compiler package for removal in 3.0.Brett Cannon2008-05-101-2/+2
|
* Another test for __future__ print_function.Eric Smith2008-03-191-0/+11
|
* Patch #2167 from calvin: Remove unused importsChristian Heimes2008-02-231-1/+2
|
* Patch #1031213: Decode source line in SyntaxErrors back to its originalMartin v. Löwis2007-09-041-0/+26
| | | | source encoding. Will backport to 2.5.
* Patch #1638243: the compiler package is now able to correctly compileGeorg Brandl2007-01-271-0/+31
| | | | | a with statement; previously, executing code containing a with statement compiled by the compiler package crashed the interpreter.
* Fix a bug in the ``compiler`` package that caused invalid code to beNeil Schemenauer2006-08-161-0/+7
| | | | generated for generator expressions.
* Whitespace normalization.Tim Peters2006-08-041-1/+1
|
* Fix the 'compiler' package to generate correct code for MAKE_CLOSURE.Neil Schemenauer2006-08-041-0/+13
| | | | | | In the 2.5 development cycle, MAKE_CLOSURE as changed to take free variables as a tuple rather than as individual items on the stack. Closes patch #1534084.
* Bug #1441397: The compiler module now recognizes module and functionGeorg Brandl2006-07-291-0/+8
| | | | docstrings correctly as it did in Python 2.4.
* Test for correct compilation of try-except-finally stmt.Georg Brandl2006-06-221-0/+15
| | | | Test for correct lineno on list, tuple, dict literals.
* Make use of new str.startswith/endswith semantics.Georg Brandl2006-06-091-1/+1
| | | | Occurences in email and compiler were ignored due to backwards compat requirements.
* Bug #1385040: don't allow "def foo(a=1, b): pass" in the compiler package.Georg Brandl2006-05-031-0/+3
|
* Try to really fix the slow buildbots this time.Neal Norwitz2006-04-281-0/+1
| | | | | | Printing to stdout, doesn't mean the data was actually written. It depends on the buffering, so we need to flush. This will hopefully really fix the buildbots getting killed due to no output on the slow bots.
* test_compile can be really long if we are using -u compiler.Neal Norwitz2006-04-131-2/+11
| | | | | | | | | This may be causing the debian sparc buildbot to fail. Print a little message to let the user ^w buildbot know it's still thinking. We may want to adjust the time period which is currently 5 minutes. Will backport.
* Fix failure of test_compiler.py when compiling test_contextlib.py.Guido van Rossum2006-03-021-1/+4
| | | | | | The culprit was an expression-less yield -- the first apparently in the standard library. I added a unit test for this. Also removed the hack to force compilation of test_with.py.
* Reformat the exception message by going through a list.Martin v. Löwis2006-03-011-1/+3
|
* Make failures in test cases print failing source file.Martin v. Löwis2006-03-011-1/+5
|
* Update the compiler package to compile the with-statement.Guido van Rossum2006-02-281-1/+1
| | | | Jeremy, please review!
* Revert revision 41940: the test causes -uall toTim Peters2006-01-071-4/+1
| | | | fail everywhere.
* Add compiler test regarding optional arguments.Georg Brandl2006-01-061-1/+4
|
* Fix compiler test when run with -u (long mode)Neal Norwitz2005-10-241-1/+1
|
* Fix compiler.ast.flatten function so that it works on lists.Neil Schemenauer2005-06-021-0/+5
|
* Whitespace normalization.Tim Peters2005-04-201-1/+1
|
* Flush out support for ``class B(): pass`` syntax by adding support to theBrett Cannon2005-04-091-0/+3
| | | | | | 'parser' module and 'compiler' package. Closes patch #1176012. Thanks logistix.
* test for fixedness of bug #1057835.Michael W. Hudson2004-11-081-0/+2
| | | | (thanks to Raymond for the prod).
* Open source files in universal newlines mode.Michael W. Hudson2004-10-111-1/+1
|
* Whitespace normalization.Tim Peters2004-09-121-4/+4
|
* compiler.transformer: correct lineno attribute when possibleJeremy Hylton2004-09-071-0/+59
| | | | | | | | | | | | | | | | SF patch #1015989 The basic idea of this patch is to compute lineno attributes for all AST nodes. The actual implementation lead to a lot of restructing and code cleanup. The generated AST nodes now have an optional lineno argument to constructor. Remove the top-level asList(), since it didn't seem to serve any purpose. Add an __iter__ to ast nodes. Use isinstance() instead of explicit type tests. Change transformer to use the new lineno attribute, which replaces three lines of code with one. Use universal newlines so that we can get rid of special-case code for line endings. Use lookup_node() in a few more frequently called, but simple com_xxx methods(). Change string exception to class exception.
* Change the strategy for coping with time intensive tests fromRaymond Hettinger2004-09-041-1/+5
| | | | | | | | "all or none" to "all or some". This provides much greater test coverage without eating much time. It also makes it more likely that routine regression testing will unearth bugs.
* Tell unittest that source files with "badsyntax" in their names shouldTim Peters2004-08-081-1/+5
| | | | | raise SyntaxError. test_compiler passes now on WinXP, at least in a release-build non-O run.
* Renamed locals to better reflect their meanings.Tim Peters2004-08-081-6/+6
|
* In verbose mode, display the name of each file before trying to compileTim Peters2004-08-081-1/+4
| | | | | it. Else when this fails, there's no way to tell which file it was chewing on.
* Whitespace normalization.Tim Peters2004-08-081-3/+0
|
* Add a trivial test for the compiler package, guarded by compiler resource.Jeremy Hylton2004-08-071-0/+34
This test is insanely slow, so it requires a resource. On my machine, it also appears to dump core. I think the problem is a stack overflow, but haven't been able to confirm.