Issue 1441408: svn head compiler fails to spot extended slicing (original) (raw)

Issue1441408

This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

This issue has been migrated to GitHub: https://github.com/python/cpython/issues/42963

classification

Title: svn head compiler fails to spot extended slicing
Type: Stage:
Components: Interpreter Core Versions:

process

Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: logistix, mwh, ncoghlan
Priority: normal Keywords:

Created on 2006-03-02 01:20 by mwh, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Messages (5)
msg27641 - (view) Author: Michael Hudson (mwh) (Python committer) Date: 2006-03-02 01:20
This is Python SVN HEAD: >>> dis.dis(compile("x[::]", '', 'single')) 1 0 LOAD_NAME 0 (x) 3 SLICE+0 4 PRINT_EXPR 5 LOAD_CONST 0 (None) 8 RETURN_VALUE This is Python 2.4: >>> dis.dis(compile("x[::]", '', 'single')) 1 0 LOAD_NAME 0 (x) 3 LOAD_CONST 0 (None) 6 LOAD_CONST 0 (None) 9 LOAD_CONST 0 (None) 12 BUILD_SLICE 3 15 BINARY_SUBSCR 16 PRINT_EXPR 17 LOAD_CONST 0 (None) 20 RETURN_VALUE
msg27642 - (view) Author: Grant Olson (logistix) Date: 2006-03-05 23:33
Logged In: YES user_id=699438 This only happens when you have implicit slice values. x[1:2:3] works fine. I'm finishing up a patch and will post to sf shortly.
msg27643 - (view) Author: Grant Olson (logistix) Date: 2006-03-10 00:22
Logged In: YES user_id=699438 Patch 1446847 Posted.
msg27644 - (view) Author: Alyssa Coghlan (ncoghlan) * (Python committer) Date: 2006-03-17 13:45
Logged In: YES user_id=1038590 Alternate patch that doesn't modify the AST posted as 1452332
msg27645 - (view) Author: Alyssa Coghlan (ncoghlan) * (Python committer) Date: 2006-03-17 18:04
Logged In: YES user_id=1038590 Applied 1452332 to SVN (generates an explicit None reference for the step when the second colon is present but no expressions is supplied for the step)
History
Date User Action Args
2022-04-11 14:56:15 admin set github: 42963
2006-03-02 01:20:13 mwh create