|
Karsten Hopp |
7be4c3 |
To: vim_dev@googlegroups.com
|
|
Karsten Hopp |
7be4c3 |
Subject: Patch 7.3.881
|
|
Karsten Hopp |
7be4c3 |
Fcc: outbox
|
|
Karsten Hopp |
7be4c3 |
From: Bram Moolenaar <Bram@moolenaar.net>
|
|
Karsten Hopp |
7be4c3 |
Mime-Version: 1.0
|
|
Karsten Hopp |
7be4c3 |
Content-Type: text/plain; charset=UTF-8
|
|
Karsten Hopp |
7be4c3 |
Content-Transfer-Encoding: 8bit
|
|
Karsten Hopp |
7be4c3 |
------------
|
|
Karsten Hopp |
7be4c3 |
|
|
Karsten Hopp |
7be4c3 |
Patch 7.3.881
|
|
Karsten Hopp |
7be4c3 |
Problem: Python list does not work correctly.
|
|
Karsten Hopp |
7be4c3 |
Solution: Fix it and add a test. (Yukihiro Nakadaira)
|
|
Karsten Hopp |
7be4c3 |
Files: src/testdir/test86.in, src/testdir/test86.ok, src/if_py_both.h
|
|
Karsten Hopp |
7be4c3 |
|
|
Karsten Hopp |
7be4c3 |
|
|
Karsten Hopp |
7be4c3 |
*** ../vim-7.3.880/src/testdir/test86.in 2013-02-20 16:54:24.000000000 +0100
|
|
Karsten Hopp |
7be4c3 |
--- src/testdir/test86.in 2013-04-05 19:18:48.000000000 +0200
|
|
Karsten Hopp |
7be4c3 |
***************
|
|
Karsten Hopp |
7be4c3 |
*** 321,326 ****
|
|
Karsten Hopp |
7be4c3 |
--- 321,351 ----
|
|
Karsten Hopp |
7be4c3 |
:py trace_main()
|
|
Karsten Hopp |
7be4c3 |
:py sys.settrace(None)
|
|
Karsten Hopp |
7be4c3 |
:$put =string(l)
|
|
Karsten Hopp |
7be4c3 |
+ :"
|
|
Karsten Hopp |
7be4c3 |
+ :" Slice
|
|
Karsten Hopp |
7be4c3 |
+ :py ll = vim.bindeval('[0, 1, 2, 3, 4, 5]')
|
|
Karsten Hopp |
7be4c3 |
+ :py l = ll[:4]
|
|
Karsten Hopp |
7be4c3 |
+ :$put =string(pyeval('l'))
|
|
Karsten Hopp |
7be4c3 |
+ :py l = ll[2:]
|
|
Karsten Hopp |
7be4c3 |
+ :$put =string(pyeval('l'))
|
|
Karsten Hopp |
7be4c3 |
+ :py l = ll[:-4]
|
|
Karsten Hopp |
7be4c3 |
+ :$put =string(pyeval('l'))
|
|
Karsten Hopp |
7be4c3 |
+ :py l = ll[-2:]
|
|
Karsten Hopp |
7be4c3 |
+ :$put =string(pyeval('l'))
|
|
Karsten Hopp |
7be4c3 |
+ :py l = ll[2:4]
|
|
Karsten Hopp |
7be4c3 |
+ :$put =string(pyeval('l'))
|
|
Karsten Hopp |
7be4c3 |
+ :py l = ll[4:2]
|
|
Karsten Hopp |
7be4c3 |
+ :$put =string(pyeval('l'))
|
|
Karsten Hopp |
7be4c3 |
+ :py l = ll[-4:-2]
|
|
Karsten Hopp |
7be4c3 |
+ :$put =string(pyeval('l'))
|
|
Karsten Hopp |
7be4c3 |
+ :py l = ll[-2:-4]
|
|
Karsten Hopp |
7be4c3 |
+ :$put =string(pyeval('l'))
|
|
Karsten Hopp |
7be4c3 |
+ :py l = ll[:]
|
|
Karsten Hopp |
7be4c3 |
+ :$put =string(pyeval('l'))
|
|
Karsten Hopp |
7be4c3 |
+ :py l = ll[0:6]
|
|
Karsten Hopp |
7be4c3 |
+ :$put =string(pyeval('l'))
|
|
Karsten Hopp |
7be4c3 |
+ :py l = ll[-10:10]
|
|
Karsten Hopp |
7be4c3 |
+ :$put =string(pyeval('l'))
|
|
Karsten Hopp |
7be4c3 |
:endfun
|
|
Karsten Hopp |
7be4c3 |
:"
|
|
Karsten Hopp |
7be4c3 |
:call Test()
|
|
Karsten Hopp |
7be4c3 |
*** ../vim-7.3.880/src/testdir/test86.ok 2013-02-20 16:54:24.000000000 +0100
|
|
Karsten Hopp |
7be4c3 |
--- src/testdir/test86.ok 2013-04-05 19:18:48.000000000 +0200
|
|
Karsten Hopp |
7be4c3 |
***************
|
|
Karsten Hopp |
7be4c3 |
*** 65,67 ****
|
|
Karsten Hopp |
7be4c3 |
--- 65,78 ----
|
|
Karsten Hopp |
7be4c3 |
vim: Vim(let):E859:
|
|
Karsten Hopp |
7be4c3 |
[1]
|
|
Karsten Hopp |
7be4c3 |
[1, 10, 11, 10, 11, 10, 11, 10, 11, 10, 11, 10, 1]
|
|
Karsten Hopp |
7be4c3 |
+ [0, 1, 2, 3]
|
|
Karsten Hopp |
7be4c3 |
+ [2, 3, 4, 5]
|
|
Karsten Hopp |
7be4c3 |
+ [0, 1]
|
|
Karsten Hopp |
7be4c3 |
+ [4, 5]
|
|
Karsten Hopp |
7be4c3 |
+ [2, 3]
|
|
Karsten Hopp |
7be4c3 |
+ []
|
|
Karsten Hopp |
7be4c3 |
+ [2, 3]
|
|
Karsten Hopp |
7be4c3 |
+ []
|
|
Karsten Hopp |
7be4c3 |
+ [0, 1, 2, 3, 4, 5]
|
|
Karsten Hopp |
7be4c3 |
+ [0, 1, 2, 3, 4, 5]
|
|
Karsten Hopp |
7be4c3 |
+ [0, 1, 2, 3, 4, 5]
|
|
Karsten Hopp |
7be4c3 |
*** ../vim-7.3.880/src/if_py_both.h 2013-02-14 22:11:31.000000000 +0100
|
|
Karsten Hopp |
7be4c3 |
--- src/if_py_both.h 2013-04-05 19:27:46.000000000 +0200
|
|
Karsten Hopp |
7be4c3 |
***************
|
|
Karsten Hopp |
7be4c3 |
*** 1139,1145 ****
|
|
Karsten Hopp |
7be4c3 |
|
|
Karsten Hopp |
7be4c3 |
for (i = 0; i < n; ++i)
|
|
Karsten Hopp |
7be4c3 |
{
|
|
Karsten Hopp |
7be4c3 |
! PyObject *item = ListItem(self, i);
|
|
Karsten Hopp |
7be4c3 |
if (item == NULL)
|
|
Karsten Hopp |
7be4c3 |
{
|
|
Karsten Hopp |
7be4c3 |
Py_DECREF(list);
|
|
Karsten Hopp |
7be4c3 |
--- 1139,1145 ----
|
|
Karsten Hopp |
7be4c3 |
|
|
Karsten Hopp |
7be4c3 |
for (i = 0; i < n; ++i)
|
|
Karsten Hopp |
7be4c3 |
{
|
|
Karsten Hopp |
7be4c3 |
! PyObject *item = ListItem(self, first + i);
|
|
Karsten Hopp |
7be4c3 |
if (item == NULL)
|
|
Karsten Hopp |
7be4c3 |
{
|
|
Karsten Hopp |
7be4c3 |
Py_DECREF(list);
|
|
Karsten Hopp |
7be4c3 |
*** ../vim-7.3.880/src/version.c 2013-04-05 18:58:42.000000000 +0200
|
|
Karsten Hopp |
7be4c3 |
--- src/version.c 2013-04-05 19:31:59.000000000 +0200
|
|
Karsten Hopp |
7be4c3 |
***************
|
|
Karsten Hopp |
7be4c3 |
*** 730,731 ****
|
|
Karsten Hopp |
7be4c3 |
--- 730,733 ----
|
|
Karsten Hopp |
7be4c3 |
{ /* Add new patch number below this line */
|
|
Karsten Hopp |
7be4c3 |
+ /**/
|
|
Karsten Hopp |
7be4c3 |
+ 881,
|
|
Karsten Hopp |
7be4c3 |
/**/
|
|
Karsten Hopp |
7be4c3 |
|
|
Karsten Hopp |
7be4c3 |
--
|
|
Karsten Hopp |
7be4c3 |
hundred-and-one symptoms of being an internet addict:
|
|
Karsten Hopp |
7be4c3 |
123. You ask the car dealer to install an extra cigarette lighter
|
|
Karsten Hopp |
7be4c3 |
on your new car to power your notebook.
|
|
Karsten Hopp |
7be4c3 |
|
|
Karsten Hopp |
7be4c3 |
/// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
|
|
Karsten Hopp |
7be4c3 |
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
|
|
Karsten Hopp |
7be4c3 |
\\\ an exciting new programming language -- http://www.Zimbu.org ///
|
|
Karsten Hopp |
7be4c3 |
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
|