Carl Meyer
d52c4482a8
gh-108654: restore comprehension locals before handling exception ( #108659 )
...
Co-authored-by: Dong-hee Na <donghee.na92@gmail.com>
2023-08-30 17:50:50 -06:00
Carl Meyer
104d7b760f
gh-105340: include hidden fast-locals in locals() ( #105715 )
...
* gh-105340: include hidden fast-locals in locals()
2023-07-05 17:05:02 -06:00
Jelle Zijlstra
dbe171e609
gh-104602: Add additional test for listcomp with lambda ( #104639 )
...
This threw a SystemError before #104603 . Adding a separate test
because this was a different failure mode than the other two new
tests from #104603 , both of which used to segfault.
2023-05-19 09:16:39 -06:00
Carl Meyer
70c7796477
gh-104619: never leak comprehension locals to outer locals() ( #104637 )
2023-05-18 18:50:24 -07:00
Carl Meyer
86e6f16ccb
gh-104602: ensure all cellvars are known up front ( #104603 )
...
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2023-05-19 00:07:35 +00:00
Carl Meyer
0589c6a4d3
gh-104615: don't make unsafe swaps in apply_static_swaps ( #104620 )
2023-05-18 21:22:03 +00:00
Jelle Zijlstra
662aede68b
gh-104374: Remove access to class scopes for inlined comprehensions ( #104528 )
...
Co-authored-by: Carl Meyer <carl@oddbird.net>
2023-05-18 05:22:17 +00:00
Carl Meyer
563c7dcba0
gh-104404: fix crasher with nested comprehensions plus lambdas ( #104442 )
2023-05-12 17:42:04 -07:00
Carl Meyer
ac66cc17f2
gh-104377: fix cell in comprehension that is free in outer scope ( #104394 )
2023-05-11 16:48:21 -07:00
Carl Meyer
fcd5fb49b1
gh-104357: fix inlined comprehensions that close over iteration var ( #104368 )
2023-05-10 18:08:40 -07:00
Carl Meyer
c3b595e73e
gh-97933: (PEP 709) inline list/dict/set comprehensions ( #101441 )
...
Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
2023-05-09 11:02:14 -06:00
Serhiy Storchaka
a856364cc9
bpo-45229: Use doctest.DocTestSuite instead of run_doctest (GH-28468)
...
Alo use load_tests() for adding tests.
2021-09-20 11:36:57 +03:00
Serhiy Storchaka
8c579b1cc8
bpo-32856: Optimize the assignment idiom in comprehensions. (GH-16814)
...
Now `for y in [expr]` in comprehensions is as fast as a simple
assignment `y = expr`.
2020-02-12 12:18:59 +02:00
Zackery Spytz
ceb93f4540
bpo-31027: Fix test_listcomps failure when run directly ( #2939 )
...
Bug appears to be incomplete copy-paste-edit.
2017-07-29 12:05:55 -04:00
Benjamin Peterson
8c84b71c88
having three copies of the same test is surely a bit excessive
2010-12-12 01:46:43 +00:00
Benjamin Peterson
ee8712cda4
#2621 rename test.test_support to test.support
2008-05-20 21:35:26 +00:00
Guido van Rossum
0368b726a1
Merged revisions 55225-55227,55229-55269 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/p3yk
................
r55238 | guido.van.rossum | 2007-05-10 16:46:05 -0700 (Thu, 10 May 2007) | 9 lines
Merged revisions 55227 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r55227 | guido.van.rossum | 2007-05-10 10:20:15 -0700 (Thu, 10 May 2007) | 2 lines
Fix a bug in test_c_api() that caused a negative refcount.
........
................
r55246 | neal.norwitz | 2007-05-11 00:01:52 -0700 (Fri, 11 May 2007) | 1 line
Remove commands.getstatus() it is obsolete.
................
r55248 | neal.norwitz | 2007-05-11 00:29:05 -0700 (Fri, 11 May 2007) | 2 lines
Remove bsddb185 support.
................
r55249 | neal.norwitz | 2007-05-11 00:29:50 -0700 (Fri, 11 May 2007) | 1 line
Remove bsddb185 module too
................
r55250 | neal.norwitz | 2007-05-11 00:32:13 -0700 (Fri, 11 May 2007) | 1 line
bsddb185: Gotta remove from the file checked in, not Setup
................
r55251 | neal.norwitz | 2007-05-11 00:53:26 -0700 (Fri, 11 May 2007) | 1 line
Remove obsolete IRIX modules (as much as I could find, there is probably more)
................
r55252 | neal.norwitz | 2007-05-11 00:55:35 -0700 (Fri, 11 May 2007) | 1 line
Remove SGI turd.
................
r55254 | georg.brandl | 2007-05-11 03:11:01 -0700 (Fri, 11 May 2007) | 2 lines
Add a case for set comprehensions to the "cannot assign to" switch.
................
r55255 | georg.brandl | 2007-05-11 03:11:25 -0700 (Fri, 11 May 2007) | 2 lines
Fix wrong imports.
................
r55261 | georg.brandl | 2007-05-11 07:37:48 -0700 (Fri, 11 May 2007) | 2 lines
Remove removed tex files.
................
r55262 | georg.brandl | 2007-05-11 08:28:41 -0700 (Fri, 11 May 2007) | 2 lines
Commit PEP 3132 implementation.
................
r55264 | georg.brandl | 2007-05-11 08:50:19 -0700 (Fri, 11 May 2007) | 2 lines
Check in the inevitable AST version number and format Py_ssize_t with %zd.
................
r55265 | neal.norwitz | 2007-05-11 09:12:22 -0700 (Fri, 11 May 2007) | 1 line
Remove mention of os.popen* and popen2.* since these will be removed.
................
r55266 | neal.norwitz | 2007-05-11 09:19:57 -0700 (Fri, 11 May 2007) | 1 line
Get doc to build again (almost, the doc is fine)
................
r55267 | neal.norwitz | 2007-05-11 09:21:02 -0700 (Fri, 11 May 2007) | 1 line
Really get doc to build (remove use of string module)
................
r55269 | neal.norwitz | 2007-05-11 09:29:43 -0700 (Fri, 11 May 2007) | 1 line
Add some notes to cleanup later
................
2007-05-11 16:50:42 +00:00
Guido van Rossum
805365ee39
Merged revisions 55007-55179 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/p3yk
........
r55077 | guido.van.rossum | 2007-05-02 11:54:37 -0700 (Wed, 02 May 2007) | 2 lines
Use the new print syntax, at least.
........
r55142 | fred.drake | 2007-05-04 21:27:30 -0700 (Fri, 04 May 2007) | 1 line
remove old cruftiness
........
r55143 | fred.drake | 2007-05-04 21:52:16 -0700 (Fri, 04 May 2007) | 1 line
make this work with the new Python
........
r55162 | neal.norwitz | 2007-05-06 22:29:18 -0700 (Sun, 06 May 2007) | 1 line
Get asdl code gen working with Python 2.3. Should continue to work with 3.0
........
r55164 | neal.norwitz | 2007-05-07 00:00:38 -0700 (Mon, 07 May 2007) | 1 line
Verify checkins to p3yk (sic) branch go to 3000 list.
........
r55166 | neal.norwitz | 2007-05-07 00:12:35 -0700 (Mon, 07 May 2007) | 1 line
Fix this test so it runs again by importing warnings_test properly.
........
r55167 | neal.norwitz | 2007-05-07 01:03:22 -0700 (Mon, 07 May 2007) | 8 lines
So long xrange. range() now supports values that are outside
-sys.maxint to sys.maxint. floats raise a TypeError.
This has been sitting for a long time. It probably has some problems and
needs cleanup. Objects/rangeobject.c now uses 4-space indents since
it is almost completely new.
........
r55171 | guido.van.rossum | 2007-05-07 10:21:26 -0700 (Mon, 07 May 2007) | 4 lines
Fix two tests that were previously depending on significant spaces
at the end of a line (and before that on Python 2.x print behavior
that has no exact equivalent in 3.0).
........
2007-05-07 22:24:25 +00:00
Nick Coghlan
650f0d06d3
Hide list comp variables and support set comprehensions
2007-04-15 12:05:43 +00:00